Brad(ley), Comparing your page to the example provided at http://code.google.com/apis/maps/documentation/v3/examples/overlay-simple.html , it looks like your problem lies with the fact that you are adding the overlay to the map only using a center point coordinate. What you need to do is set the "bounds" for the overlay with two sets of coordinates (in the example, they have the ne corner and sw corner coordinates). This way when you zoom in/out or move the map, it knows where to keep the overlay positioned / sized correctly. The way you have it, it only knows where to put the center of the box, but the size of the box remains the same if you zoom in or out because the bounds weren't defined.
Hope this helps! -Brad On May 8, 6:00 am, Bradley <[email protected]> wrote: > http://simple-spring-28.heroku.com/is the sample (may take a sec to > load first time) > > This will eventually be a custom SVG overlay (hence the Circle > reference in the JS), but the first thing I noticed while building it > is that as I move the map, the overlay jumps around. I want it to > stick to one lat/lng. > > So initially it's over africa, but if you move it, the overlay can end > up over south america or europe etc... I imagine this has something > to do with projection?? but I'm not totally sure. > > What do I need to do to bind this div's center to the one point on the > map? Any help is greatly appreciated. > > Brad > > -- > 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 [email protected]. > To unsubscribe from this group, send email to > [email protected]. > For more options, visit this group > athttp://groups.google.com/group/google-maps-js-api-v3?hl=en. -- 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 [email protected]. To unsubscribe from this group, send email to [email protected]. For more options, visit this group at http://groups.google.com/group/google-maps-js-api-v3?hl=en.
