开发者

Serving GPS coordinates from Android localhost 10.0.2.2

Is it possible to set up a localhost server on Android so that a browser window can access the devic开发者_如何学Pythone's GPS coordinates?

I'd like to be able to access the GPS coordinates in Javascript inside a browser window.

Now I could simply send the GPS coords to the server and read from within the browser window by reading off the server, but I was wondering if there was any way to send the GPS coordinates from the device straight into the browser window without having to go through a remote server?

It would be really great to be able to access the GPS coordinates directly from http://10.0.2.2:9999

Many thanks in advance,


Can't Javascript already read current location via navigator.geolocation or something like that? This article seems to cover a lot of ground here...

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜