Enable geolocation for local files in Mobile Chrome

I have a pretty similar question to this , though regarding a mobile Chrome or any other browser that I can install on Android.

I wrote a simple script using the HTML5 binding function, but it doesn’t work in either Mobile Chrome browser or Android 4.1. In the first case, my script returns the error code "User refused", although I did not deny anything (and although geolocation is enabled in the Chrome settings). In the system browser, the status remains at "Idle" (initial value), which leads to the fact that this bad browser is not even compatible with HTML5 and does not support jQuery, which I used.

Because I want to develop a script without connecting (a location based only on the GPS device) I need any solution that I can run on Android, and this allows me to use geolocation from a locally saved file (accessible via file:/// ). Anyone got it?

+1
android google-chrome mobile geolocation
Sep 13 '12 at 15:38
source share
1 answer

According to the error you are associated with, geolocation and many other functions are disabled for file:// URLs (as on the Chrome desktop). In regular Chrome, you can start the browser with some useful flags, such as --allow-file-access-from-files , but you can’t turn on geolocation without starting a local HTTPD.

For mobile Chrome, we're open to suggestions for new developer features. Please register this as a feature request at http://new.mcrbug.com .

+1
Sep 14 '12 at 18:21
source share



All Articles