I've been trying to use the panTo in conjunction to jquery gMap
(http://gmap.nurtext.de/download.html)

but when click in one of the links that refers to the panTo function
the map seems to broke. It appears that image when you have zoomed too
much but it doesnt work if you zoom out.


<div id="map_canvas"></div>
<script type="text/javascript">
        options = {
                            latitude:               -22.878113,
                            longitude:             -43.285918,
                            zoom:                   11,
                            markers:    [

                                                { latitude: -22.787198, 
longitude: -43.376307, html: "Shopping
Grande Rio", popup: false},

                                                { latitude: -22.937431, 
longitude: -43.06148, html:
"Piratininga", popup: false},

                                                { latitude: -22.850431, 
longitude: -43.097314, html: "São
Gonçalo Shopping", popup: false},

                                                { latitude: 
-22.922409262986587, longitude:
-43.23587894439697, html: "Shopping Tijuca", popup: false},

                                                { latitude: -22.88747, 
longitude: -43.282521, html:
"Suburbana", popup: false},

                                                { latitude: -22.878113, 
longitude: 43.285918, html: "Inhaúma",
popup: false},

                                                { latitude: -22.868405, 
longitude: -43.351662, html: "Oswaldo
Cruz", popup: false},

                                                { latitude: -22.983223, 
longitude: -43.365334, html: "Via
Parque Shopping", popup: false},

                                                { latitude: -23.014454, 
longitude: -43.466479, html:
"Recreio", popup: false},

                                                { latitude: -22.949149, 
longitude: -43.183042, html:
"Botafogo", popup: false},

                                                { latitude: -22.967442, 
longitude: -43.183966, html:
"Copacabana II", popup: false},

                                                { latitude: 
-22.974356819135682, longitude:
-43.19120407104492, html: "Copacabana", popup: false}],

                        controls:               ["GSmallMapControl", 
"GMapTypeControl"],
                        scrollwheel:            false,
                        maptype:                G_NORMAL_MAP,
                        html_prepend:           '<div class="gmap_marker">',
                        html_append:            '</div>',
                        icon:
                                        {
                                            image:              
"http://google-maps-icons.googlecode.com/
files/supermarket.png",
                                            shadow:             
"http://www.google.com/mapfiles/
shadow50.png",
                                            iconsize:           [30, 34],
                                            shadowsize:         [37, 34],
                                            iconanchor:         [9, 34],
                                            infowindowanchor:   [9, 2]
                                        }
                            };

jQuery(document).ready(function() {
                jQuery("#map_canvas").gMap(options);
                jQuery(".nom a").click(function(){
                        //alert($gmap);
                        $gmap.panTo(new GLatLng(jQuery(this).attr("rel")));
                        }
                );
        });
</script>

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

Reply via email to