This is a premium module, in order to use it you will need to upgrade your project.
forge.geolocation namespace allows you to access fine location data.
Although geolocation APIs are part of the HTML5 specification, on some platforms, the default permissions dialogs can be cumbersome. So we offer an alternative way to get geolocation data.
forge.geolocation.getCurrentPosition(options, success, error)¶
Get the user's current position.
objectrequest specific levels of service from the location provider, currently supports
"enableHighAccuracy": trueto request GPS location if available
function(position)callback with an object matching the W3C Position specification
function(content)called when the user chooses not to share their location with your app
Note: To enable easy porting from existing HTML5 code onto Forge, we also accept parameters in the order
(success, error, options)
On Android this module will add the
to your app, users will be prompted to accept this when they install