Hello,

I'm having a javascript error when I initialize the maps api. The error
is:



b[wb] is not a function
http://maps.gstatic.com/intl/en_us/mapfiles/api-3/2/9/main.js
Line 27


It guess that the code is not obfuscated correctly. Here's a snippet of
code i'm using:



function initialize_map() {

var latlng = new google.maps.LatLng(5, -2);

var myOptions = {

zoom: 6,

mapTypeId: google.maps.MapTypeId.ROADMAP,

center: latlng

};



var map = google.maps.Map(document.getElementById("map_canvas"),
myOptions);

}



function load_map_api() {

var myOptions = {

"callback": initialize_map,

"other_params": "sensor=false"

};



google.load("maps", "3", myOptions);

}



function init_modules() {

var script = document.createElement("script");

script.type = "text/javascript";

script.src = "http://www.google.com/jsapi?key=MY-KEY";;

/* This is a trick to detect when the script is loaded. When the state

* changes the closure is called. If the state is 'complete' then we call

* the function to load the map

*/

script.onreadystatechange = function() {

if (this.readyState == 'complete') {

load_map_api();

}

}

script.onload = function() {

load_map_api();

}



document.body.appendChild(script);

}



The browser i'm using is Firefox 3.6.12.

-- 
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.

Reply via email to