I made now this:

if(item == "#gmap"){
                        $.getScript("http://maps.google.com/maps?
file=api&v=2&key=ABQIAAAAp1kkS_NlSeBqN9yg50Bb9hTRRxoX5cqBbtB-
sMaIPwRkCNveuxTK0oI3HaFAjNd9OtVNIVqQYPII7g", function(){
                                alert("Script loaded and executed.");
                                setTimeout("initialize", 3000);
                                function initialize() {
                                        if (GBrowserIsCompatible()) {
                                                var map = new 
GMap2(document.getElementById("map_canvas"));
                                                var lippetal = new 
GLatLng(51.6400656,8.0973679);
                                                var text = "<b>das consulting 
team GmbH</b><br />Hultroper
Straße 40a<br>D-59510 Lippetal<br /><br /><a href='http://
maps.google.de/maps?
f=d&source=s_d&hl=de&geocode=&saddr=&daddr=Hultroper+Stra%C3%9Fe+40a,
+59510+Lippetal,(das+consulting+team+GmbH)
&sll=51.151786,10.415039&sspn=26.409941,67.675781&ie=UTF8&ll=51.737812,8.081428&spn=0.405655,1.057434&z=11'
target='_blank'><u>Routenplaner</u></a>";

                                                map.setCenter(lippetal, 9);
                                                map.addControl(new 
GSmallMapControl());
                                                map.addControl(new 
GMapTypeControl());

                                                var marker = new 
GMarker(lippetal);
                                                map.addOverlay(marker);
                                                marker.openInfoWindowHtml(text);
                                        }
                                }
                                initialize();
                        });
                }


And the following happens:

I get the message "Script loaded".
But as error in IE: "GMap2 not definded"
and in FF
GBrowserIsCompatible is not defined

What I do wrong?
Please help!

Thanks!


On 27 Mai, 12:22, Charlie <charlie...@gmail.com> wrote:
> $.getScript("url") might help

Reply via email to