I have no idea why there would be OVER_QUERY_LIMIT error, but isn't
that on a per client basis anyway? I certainly haven't made 2500
geolocation requests today. That seems very odd.

I tried to keep the code design as simple as possible. I will try
creating a createMarker function to get function closure, which could
very well be my problem. I understand I need to "rethink my design",
which is why I was posting here.The createMarker function will
hopefully help, and thanks for the code sample!

On Jul 13, 10:48 am, "geocode...@gmail.com" <geocode...@gmail.com>
wrote:
> On Jul 13, 7:27 am, "geocode...@gmail.com" <geocode...@gmail.com>
> wrote:
>
> > On Jul 13, 6:46 am, moderntymes <doug-goo...@moderntymes.com> wrote:
>
> > > Certainly that's good advice, but these locations are actually dynamic
> > > (or will be in the final version). The locations will be coming from a
> > > frequently changing database, so I'll need to be doing the geocoding.
>
> > > I think there's a problem with the programming though, and I think it
> > > is related to the Javascript closure.
>
> > Sounds to me like you need to implement your code to handle error
> > conditions better.
>
> and add a createMarker function so you get function 
> closure:http://www.geocodezip.com/cornmaze_moderntymes_com_map_testgcA.html
>
> Note that even with those few locations I get an OVER_QUERY_LIMIT
> error for one of those points.
> You will need to rethink your design.
>
>    -- Larry
>
>
>
>
>
> > > On Jul 13, 9:19 am, "geocode...@gmail.com" <geocode...@gmail.com>
> > > wrote:
>
> > > > On Jul 13, 5:43 am, moderntymes <doug-goo...@moderntymes.com> wrote:
>
> > > > > I'm trying to create a map with approximately 40 markers. Each marker
> > > > > is geocoded and has an event handler for 'clicked' that redirects to a
> > > > > new page. I've pretty much used the geocoding code straight from the
> > > > > Google API v3 site, but the code fails if I add more than 10 markers.
> > > > > On the 11th, I get a Javascript error. If I try to show more than 11,
> > > > > then all the markers disappear.
>
> > > > > I receive a rather useless (to me at least) error message: '0' is null
> > > > > or not an object.
>
> > > > > If I take out the event handler, the problem remains so it seems to be
> > > > > connected to the geocoding. I think it has something to do with these
> > > > > lines:
> > > > >    geocoder13.geocode( { 'address': '6059 S Seneca,Wichita,KS,67217'},
> > > > > function(results, status) {
> > > > >       var marker13 = new google.maps.Marker({
> > > > >          map: map,
> > > > >          position: results[0].geometry.location,
> > > > >          title:"Cox Farm"
> > > > >       });
> > > > >    });
>
> > > > > In particular, if I remove the stuff after function(results, status)
> > > > > { up to the next }, I don't get an error. Of course I also don't get
> > > > > any markers!
>
> > > > > I tried with each geocoding occurence listed separately, which you can
> > > > > see here:http://cornmaze.moderntymes.com/map.htm
>
> > > > > I also tried making a function to do the geocoding 
> > > > > here:http://cornmaze.moderntymes.com/map_testgc.htm
>
> > > > > Results are the same either way.
>
> > > > The general advice is not to geocode addresses everytime your page
> > > > loads.  Geocode them once, offline, then use the resulting coordinates
> > > > to display the markers.
>
> > > > Geocoding the addresses every time wastes google's resources, so they
> > > > have implemented rate limits and quotas.  You should only geocode
> > > > addresses you don't know in advance (like user input) on the fly.
>
> > > >   -- Larry- Hide quoted text -
>
> > > > - Show quoted text -- Hide quoted text -
>
> > > - Show quoted text -- Hide quoted text -
>
> > - Show quoted text -- Hide quoted text -
>
> - Show quoted text -

-- 
You received this message because you are subscribed to the Google Groups 
"Google Maps JavaScript API v3" group.
To post to this group, send email to google-maps-js-api...@googlegroups.com.
To unsubscribe from this group, send email to 
google-maps-js-api-v3+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/google-maps-js-api-v3?hl=en.

Reply via email to