navigator.geolocation.getCurrentPosition() permissions

26 views
Skip to first unread message

Jason Strimpel

unread,
Apr 4, 2011, 11:57:14 AM4/4/11
to Pokki Development
I started to hack together a weather pokki this morning, and I ran
into an interesting situation. Basically, I want the pokki to poll a
weather web service and update the badge with the current temperature
at a given interval. I was going to have the background JS handle this
task by getting the latitude and longitude of the user's location via
navigator.geolocation.getCurrentPosition(). Then pass this off to the
web service. However, the user must grant permission to the browser
(pokki platform) in order to retrieve the location. Does OpenCandy
have any plans to deviate from the W3C model and allow for
"unauthorized" location look ups?

PS - I know the navigator.geolocation.getCurrentPosition() is working
because I can catch a timeout error.

Jason Strimpel

unread,
Apr 4, 2011, 12:16:06 PM4/4/11
to pokki-de...@googlegroups.com
Thanks. That works and makes perfect sense.

On Mon, Apr 4, 2011 at 9:00 AM, Ernestas Stankevičius <bad.f...@gmail.com> wrote:
Just get location by IP.

Ernestas Stankevičius | +37062261064 | Tinklaraštis | Puslapių kūrimas
Reply all
Reply to author
Forward
Message has been deleted
0 new messages