Hi,
I have several problems displaying a map on my site, for a month now, when 
I think something change about Google Maps API (before all works fine, 
until version 3.29).

The page is this: http://www.emmeti.com/portal/it/default/test

I am loading API in this way, in the head of the site:

var EMT = {};

EMT.requestGoogleMapsAPI = function(callback, version, sensor) {
    if (typeof google == "object") {
        var callbackFunction = window[callback];
        if (typeof callbackFunction == "function")
            callbackFunction();
            
    } else {
        var lang = eXo.env.portal.language;
        var s = sensor || false;
        var v = version || "3.exp"
        jq.getScript(
            
"https://maps.googleapis.com/maps/api/js?v="+v+"&sensor="+s+"&language="+lang+"&callback="+callback
            ,function(){}
        );
    }
}

and then, I have in body a simple Google map, buiilt in this way:

<div class="map_canvas" id="map-canvas">
    &nbsp;</div>
<div id="gmap_contatti" style="width:100%;height:440px;background:#999">

    <script type="text/javascript">
function CARAziendaContatti_initMap () {

    var uluru = {lat: -25.363, lng: 131.044};
    var    map = new 
google.maps.Map(document.getElementById("gmap_contatti"),  {
                  zoom: 4,
                  center: uluru
            });
    
    google.maps.event.addListener(map, 'idle', function(){

        //if(!mapLoaded){
            //jq('#gmap_contatti').trigger('mapLoaded');
            var uluru = {lat: -25.363, lng: 131.044};
            map = new 
google.maps.Map(document.getElementById("gmap_contatti"),  {
                  zoom: 4,
                  center: uluru
            });
            /*var marker = new google.maps.Marker({
              position: uluru,
              map: map
            });*/
       // }
    });
}

</script><script type="text/javascript">
    function setupCARAziendaContatti () {
        EMT.requestGoogleMapsAPI("CARAziendaContatti_initMap", "3.exp");
    }
    setupCARAziendaContatti();
</script></div>

How can I fix this? Is there a way to solve this?

Regards

Simone Pesavento

-- 
You received this message because you are subscribed to the Google Groups 
"Google Maps JavaScript API v3" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to google-maps-js-api-v3+unsubscr...@googlegroups.com.
To post to this group, send email to google-maps-js-api-v3@googlegroups.com.
Visit this group at https://groups.google.com/group/google-maps-js-api-v3.
For more options, visit https://groups.google.com/d/optout.

Reply via email to