Hi there!

I am setting up a gmap for a web application and I have a simple
question.
We are implementing our site using the jQuery extension jMap. I am
pretty new with these library and I am struggling in develop our
features.

Here you can see the piece of code that load my test map.

        <script src="http://www.google.com/jsapi?
key=ABQIAAAAzQBzdMsrsDrbSFY8SPL04BSVcvQ35j2ub_6rnbii3OD971rxCxR2iyruYKNFSvYZ1QREv4hoq2xj_A"
type="text/javascript"></script>
    <script type="text/javascript">
                google.load("maps", "2.x");
        </Script>

        <script src="include/js/jquery-1.3.js" type="text/javascript"></
script>
        <script src="include/js/jquery.jmap.js" type="text/javascript"></
script>
        <script>
        $(document).ready(function() {

                var zoomBig = 4;
                var zoomdMid = 10;
                var zoomdLit = 15;

                //localization based on ip lat/lng
                //if(typeof  == 'undefined'){
                //      center = [45.75, 7.333333];
                //}else{
                //      center = new 
GLatLng(google.loader.ClientLocation.latitude,
google.loader.ClientLocation.longitude);
                //}

                center = [45.75, 7.333333];

                $('#map').jmap('init',{
                        'mapType':'map',
                        'mapCenter':center,
                        'mapZoom':zoomBig,
                        'mapEnableDoubleClickZoom':false,
                        'mapEnableSmoothZoom':false,
                        'mapEnableScrollZoom':false,
                        'mapShowjMapIcon': false
                  },
                  function (map, element, options){
                                GEvent.addListener(map, 'zoomend', 
function(oldLevel, newLevel){
                                        //$('#map').value = newLevel;
                                        //if (newLevel<=zoomdMid)
                                        alert('push marker!');
                                });
                                GEvent.addListener(map, 'click', 
function(overlay, latlang,
overlatlang){
                                        alert('click!');
                                });
                  });
        });


The map works well but the event I have added doesn't fire and the
alert doesn' appear.

Can someone help me?

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"Google Maps API" 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-API?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to