Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

is there a limit on the number of times navigator.geolocation.getCurrentPostion can be called?

This is may not be a true programming question but deals with geolocation Api, hence hoping StackOverflow is the right place for this.

I'm calling the navigator.geolocation.getCurrentPosition at every 3 seconds interval. After 10-15 tries the responses stop. So i'm wondering is there a limit on the number of calls being made, Or is it because i'm testing it with a desktop and hence instead of giving back the same response each time the API is waiting for a change of location.

Anyone has any experiences to share ?

Thanks

like image 439
Raja Avatar asked Nov 06 '22 14:11

Raja


1 Answers

There is a limit of 1500 request per window defined in the Firefox source, but since it's quite high I suspect it's a bug: http://mxr.mozilla.org/mozilla-central/source/dom/src/geolocation/nsGeolocation.cpp#96

like image 134
Wolph Avatar answered Nov 17 '22 07:11

Wolph