on 11-08-2011 11:32 AM
Hi Friends
How to Track GPS location in Workflows(HWC)? Is it possiable in SUP? If possible plz send how to solve?
Thanx in Advance.
Hello,
Currently SUP hybrid web container does not allow you to access device function with SUP 2.1,you can access camera but not GPS,however you can try out HTML5 code in cutom.js to get GPS location,the sample code is given below.
navigator.geolocation.getCurrentPosition(foundLocation, noLocation);
function foundLocation(position) {
var lat = position.coords.latitude;
var lon = position.coords.longitude;
var userLocation = lat + ', ' + lon;
$("#business-current-location, #people-current-location").remove();
$("#Near-Me")
.watermark("Current Location")
.after("<input type='hidden' name='business-current-location' id='business-current-location' value='"userLocation"' />");
$("#people-Near-Me")
.watermark("Current Location")
.after("<input type='hidden' name='people-current-location' id='people-current-location' value='"userLocation"' />");
}
regards
kaushik
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
84 | |
10 | |
10 | |
9 | |
7 | |
6 | |
5 | |
5 | |
4 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.