Hi,

How do I add an overlay on google map for wikipedia and/or youtube? I
was able to do it for panoramio. However I can't seem to find where
the kml files for these two. Here's my code for adding the panoramio.

        private void addPanoramioLayer()
        {

        GeoXmlLoadCallback cb = new GeoXmlLoadCallback() {

            public void onFailure(String url, Throwable caught)
            {
                Window.alert("Failed to load panoramio kml");
            }

            public void onSuccess(String url, GeoXmlOverlay overlay)
            {
                map.addOverlay(overlay);
            }
        };

        GeoXmlOverlay.load("http://www.panoramio.com/panoramio.kml";,
cb);
        }

I saw code on how to add it on a Google Maps via javascript but I
can't seem to do it in GWT.

function initialize() {
  if (GBrowserIsCompatible()) {
    var map = new GMap2(document.getElementById("map_canvas"));
    map.setCenter(new GLatLng(40.730885,-73.997383), 15);
    var myLayer = new GLayer("org.wikipedia.en");
    map.addOverlay(myLayer);
  }
}

http://code.google.com/apis/maps/documentation/overlays.html
http://spreadsheets.google.com/pub?key=p9pdwsai2hDN-cAocTLhnag

I tried using "org.wikipedia.en" to replace the panoramia kml location
but it didn't work. I don't think I am understanding this completely.
Should I be using something else other than GeoXmlOverlay for adding
the wikipedia overlay?

Thanks,
Milo

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

Reply via email to