我有一些代码为从浏览器获取GPS的代码。 它可以得到exacly GPS:Chrome(Window 7-PC),Firefox(Window 7-PC),Firefox(Android 5.0-Smartphone)。 但与Chrome(Android 5.0智能手机)它无法获得GPS。 我的代码:无法从Android谷歌浏览器获得GPS
function getLocation() {
if (navigator && navigator.geolocation) {
navigator.geolocation.getCurrentPosition(successGPS, errorGPS, {enableHighAccuracy: true, timeout: 60000});
} else {
console.log('Geolocation is not supported');}}
function successGPS(position) {
latLng_taxi = new google.maps.LatLng(position.coords.latitude,
position.coords.longitude);
alert(latLng_taxi);}
function errorGPS() {
alert("Cant get GPS");}
请告诉我一个关于我的问题,以及如何在Chrome浏览器(Android版)让GPS