For example,
On click of a button, Salesforce1 App tracks user location & update/create a field/record in Salesforce with location information.
Attribution to: Ganesh Bhosle
Possible Suggestion/Solution #1
You can use Google Directions API and the HTML5 Geolocation API. The Geolocation API is able to retrieve the latitude and longitude of the device’s position.
Attribution to: Sagar Pareek
Possible Suggestion/Solution #2
Salesforce1 app can be customized using publisher actions, custom tabs and mobile cards on object page layout. You can create a Visualforce page which can grab user location using javascript Geolocation API and fetch address or longitude latitude of device, which can be used to update details in associated Salesforce record same way we do in normal visualforce pages.
Google's Map is the best way to fetch user address from the location fetched from device.
There is a post similar to this: http://intmist.wordpress.com/2014/03/23/show-custom-visualforce-page-in-salesforce1-setup-publisher-action-and-check-in-using-salesforce1-app/
Attribution to: Ashwani
This content is remixed from stackoverflow or stackexchange. Please visit https://salesforce.stackexchange.com/questions/31372