Hi there!

i'm trying to load gmap scripts dynamically form via chrome extension. I 
use the following code and call it from extension's content script:

    var script = document.createElement("script");
    script.src = "https://maps.googleapis.com/maps/api/js?v=3&sensor=false";;
    script.type = "text/javascript";
    document.getElementsByTagName("head")[0].appendChild(script);

a very popular solution as you can see )

However, this only adds a corresponding tag into the head section, but 
doesn't execute the script.
e.g. main.js is not loaded.

Of coгrse, any further attempts to instantiate a map fail.. 

Beforehand thanks for any suggestions!
Andrey

-- 
You received this message because you are subscribed to the Google Groups 
"Google Maps JavaScript API v3" group.
To view this discussion on the web visit 
https://groups.google.com/d/msg/google-maps-js-api-v3/-/AVOpkAK69zQJ.
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