You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@cordova.apache.org by GitBox <gi...@apache.org> on 2020/09/05 01:06:41 UTC

[GitHub] [cordova-plugin-geolocation] alexisqc92 opened a new issue #210: Permission Request and watchposition

alexisqc92 opened a new issue #210:
URL: https://github.com/apache/cordova-plugin-geolocation/issues/210


   Hi, I was using the plugin to get the user location, but when I started the app it only shows the option to allow get location while use, instead  of always, is there a way to get this permission to always, because I am using the plugin backgroundmode also to be able to get the use locatioin while on background, and it works for a while then it stops.
   
   Also, when I am using watchposition I get an empty array and cant access the coords, is this a bug? Or maybe I am doing something wrong


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@cordova.apache.org
For additional commands, e-mail: issues-help@cordova.apache.org


[GitHub] [cordova-plugin-geolocation] breautek closed issue #210: Permission Request and watchposition

Posted by GitBox <gi...@apache.org>.
breautek closed issue #210:
URL: https://github.com/apache/cordova-plugin-geolocation/issues/210


   


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@cordova.apache.org
For additional commands, e-mail: issues-help@cordova.apache.org


[GitHub] [cordova-plugin-geolocation] alexisqc92 commented on issue #210: Permission Request and watchposition

Posted by GitBox <gi...@apache.org>.
alexisqc92 commented on issue #210:
URL: https://github.com/apache/cordova-plugin-geolocation/issues/210#issuecomment-700175330


   @ppiacez to be honest I search a lot but could not find any solution for this problem, the only thing I was able to do is consider changing to Flutter or ReactNative, which according to what I have search background geolocation is not a problem. But if you were able to find a solution let me know, thanks


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@cordova.apache.org
For additional commands, e-mail: issues-help@cordova.apache.org


[GitHub] [cordova-plugin-geolocation] 50l3r commented on issue #210: Permission Request and watchposition

Posted by GitBox <gi...@apache.org>.
50l3r commented on issue #210:
URL: https://github.com/apache/cordova-plugin-geolocation/issues/210#issuecomment-748318289


   Im interested on this. I have the same problem


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@cordova.apache.org
For additional commands, e-mail: issues-help@cordova.apache.org


[GitHub] [cordova-plugin-geolocation] breautek commented on issue #210: Permission Request and watchposition

Posted by GitBox <gi...@apache.org>.
breautek commented on issue #210:
URL: https://github.com/apache/cordova-plugin-geolocation/issues/210#issuecomment-748350592


   > it only shows the option to allow get location while use, instead of always, is there a way to get this permission to always,
   
   I'm not sure how you are accessing geolocation from the background as this plugin doesn't really support this due to limitations.
   
   On Android, we don't have a geolocation implemented, we just use the browser implementation. The plugin is purely to manage permissions. This is problematic for background usage as apps in the background has no activity and the webview cannot exists outside of an Activity. For iOS, the webview is completely paused while the app is in the background. So it cannot receive GPS events during in the background.
   
   If you need background support, a third-party plugin will be required that sets up the proper background services and provides the ability to send updates to the webview when the webview is capable of handling those updates (ie when it comes into the foreground).
   
   > Also, when I am using watchposition I get an empty array and cant access the coords,
   
   This plugin doesn't pass arrays for coordinates. It passes an object with the following properties:
   
   ```javascript
   var onSuccess = function(position) {
           alert('Latitude: '          + position.coords.latitude          + '\n' +
                 'Longitude: '         + position.coords.longitude         + '\n' +
                 'Altitude: '          + position.coords.altitude          + '\n' +
                 'Accuracy: '          + position.coords.accuracy          + '\n' +
                 'Altitude Accuracy: ' + position.coords.altitudeAccuracy  + '\n' +
                 'Heading: '           + position.coords.heading           + '\n' +
                 'Speed: '             + position.coords.speed             + '\n' +
                 'Timestamp: '         + position.timestamp                + '\n');
       };
   ```


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@cordova.apache.org
For additional commands, e-mail: issues-help@cordova.apache.org


[GitHub] [cordova-plugin-geolocation] ppiacez commented on issue #210: Permission Request and watchposition

Posted by GitBox <gi...@apache.org>.
ppiacez commented on issue #210:
URL: https://github.com/apache/cordova-plugin-geolocation/issues/210#issuecomment-699857037


   Hi, did you managed to solve? I've the same issue. Thanks


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@cordova.apache.org
For additional commands, e-mail: issues-help@cordova.apache.org