geolocation

Http sites does not detect the location in Chrome - issue

岁酱吖の 提交于 2019-12-18 04:45:08
问题 We did notice today an issue in automatic detection of zip code based on the user s location. it worked well in other browsers(edge, IE, Firefox) We had to configure the sites to https and then it works ok Example : https://www.whatismyzip.com/ works well where as http://www.mapdevelopers.com/what-is-my-zip-code.php does'nt work. <script type="text/javascript" src="https://maps.googleapis.com/maps/api/js?key=AIzaSyAdGQKI4sEj5TZAjNCds422V_ZHevD45Fo"></script> <%-- <script type="text/javascript

Background Geolocation ServiceWorker - onMessage Event order when Web App regains focus [closed]

女生的网名这么多〃 提交于 2019-12-18 04:34:05
问题 Closed . This question needs to be more focused. It is not currently accepting answers. Want to improve this question? Update the question so it focuses on one problem only by editing this post. Closed last year . For complete details, and a more lengthy description, please refer to this W3C Service worker issue. This is my HTML5 Web App scenario: - My Web App has been backgrounded and stuck in my pocket while I go for a ride As I clock up the KMs my Service Worker(s) is regularly receiving

locationManager.getLastKnownLocation() return null

久未见 提交于 2019-12-18 04:00:08
问题 i dont understand why locationManager.getLastKnownLocation(LocationManager.GPS_PROVIDER); return the location null. I gave all permission but its reutning null . if (isGPSEnabled) { if (location == null) { locationManager.requestLocationUpdates( LocationManager.GPS_PROVIDER, MIN_TIME_BW_UPDATES, MIN_DISTANCE_CHANGE_FOR_UPDATES, this); Log.d("GPS", "GPS Enabled"); if (locationManager != null) { location = locationManager .getLastKnownLocation(LocationManager.GPS_PROVIDER); if (location != null

Geographic Midpoint between two coordinates

杀马特。学长 韩版系。学妹 提交于 2019-12-18 03:40:27
问题 I have been using the Moveable-Type website to aid me in some Geocoordinate calcuations and it's been very useful, however, I have a bug in my calculation of the mid-point between two coordinates. My result is close to the expected, but not close enough: posA = {47.64570362, -122.14073746} posB = {47.64316917, -122.14032175} expected result (taken from the movable type calculator) = 47°38′40″N, 122°08′26″W = {47.644444, -122.140556} my result: {49.6054801645915, -122.14052959995759} Here is

Geographic Midpoint between two coordinates

☆樱花仙子☆ 提交于 2019-12-18 03:40:03
问题 I have been using the Moveable-Type website to aid me in some Geocoordinate calcuations and it's been very useful, however, I have a bug in my calculation of the mid-point between two coordinates. My result is close to the expected, but not close enough: posA = {47.64570362, -122.14073746} posB = {47.64316917, -122.14032175} expected result (taken from the movable type calculator) = 47°38′40″N, 122°08′26″W = {47.644444, -122.140556} my result: {49.6054801645915, -122.14052959995759} Here is

How HTML5 Geolocation Feature Works?

余生颓废 提交于 2019-12-18 03:05:25
问题 How can the browser tell where I am? Totally based on registered IP address? What if I'm behind a proxy? 回答1: That would depend on the browser and its settings. It might use GPS, WLAN AP-based location, IP location, or any other conceivable method of locating itself. The browser runs on your local machine, so even if you're behind a proxy, it should be able to find your actual IP address (unless security features prevent it from being sent for lookup to a geolocation server). Whether any

Find centerpoint of polygon in JavaScript

时光总嘲笑我的痴心妄想 提交于 2019-12-18 02:50:42
问题 I have a "place" object from Google Maps which has a set of coordinates that represent a bounding box for a given location, say London. Each set of coordinates has a latitude and longitude. I have written the below code to find the centerpoint, but I am not sure if it does actually produce the centerpoint. What if the polygon has 5 points instead of 4? Also, can this be done in a more efficient way, with less operations? function average(array) { // Add together and then divide by the length

Using geo-coordinates as vertex coordinates in the igraph r-package

牧云@^-^@ 提交于 2019-12-18 01:19:46
问题 In the igraph package for R, I am struggling to plot a social network using latitude/longitude coordinates as the layout of the graph. Imagine this simple example: a network with 4 nodes of which you know the geographical location and the connections: df<-data.frame("from" = c("Bob", "Klaus", "Edith", "Liu"), "to"= c("Edith", "Edith", "Bob", "Klaus")) Here you have the meta-data for the nodes, so that Bob lives in NY, Klaus in Berlin, Edith in Paris and Liu in Bejing: meta <- data.frame("name

navigator.geolocation getCurrentPosition not updating in Chrome Mobile

戏子无情 提交于 2019-12-18 01:13:29
问题 I have created a site (can be accessed at http://dev.gkr33.com) which is designed for a smartphone and attempts to use the navigator.geolocation api and grab your position via getCurrentPosition. This seems to work initially, however if you try to refresh the page it always brings back the last GPS position. I have added some debug information on the page which grabs the time of the getCurrentPosition return and after the initial positioning it always returns the same time (down to the

navigator.geolocation getCurrentPosition not updating in Chrome Mobile

淺唱寂寞╮ 提交于 2019-12-18 01:13:22
问题 I have created a site (can be accessed at http://dev.gkr33.com) which is designed for a smartphone and attempts to use the navigator.geolocation api and grab your position via getCurrentPosition. This seems to work initially, however if you try to refresh the page it always brings back the last GPS position. I have added some debug information on the page which grabs the time of the getCurrentPosition return and after the initial positioning it always returns the same time (down to the