Reputation: 51
When I use the geolocation service in the usual manner like for example :
if (navigator.geolocation) {
navigator.geolocation.getCurrentPosition(showPosition1,errLocation, {maximumAge:0, timeout:40000, enableHighAccuracy:true});
}
function showPosition1(position) {console.log(position.coords)}
I get a result which is extremely off. When I check using position.coord.accuracy, it shows to be 260 km! That is very far from where I am.
Any idea why this is the case even though highAccuracy is enabled and the browser permits location and everything?
I am using my mobile data's hotspot to connect to internet on my laptop. Can this be a big issue?
Upvotes: 5
Views: 2750
Reputation: 23863
GeoLocation features use MANY different ways to figure out your location. In addition to the standard ways, Chrome at least one additional.
If your access point moved, it can throw off things. If you have to resort to Geo-IP, accuracy is a crap-shoot.
In addition, using proxy servers or VPNs will make Geo-IP useless.
Upvotes: 4