On 27 Juli, 10:20, Rossko <[email protected]> wrote:
> > But, being a nobody on javascript, and not so keen on having a list at
> > the side of the map.
> > And trying to remove it, the markers will also be removed.
> > It gets really cluttered trying to read the source when it is all
> > connected to that list.
>
> No-one said using the maps API was easy.
> If you're asking for help, you'll have to help us 
> ...http://groups.google.com/group/Google-Maps-API/web/suggested-posting-...



Here you got my uploaded map:
http://dots.axesgame.com/map/

I have been trying to copy the 'Loading the data from XML'-tutorial,
while removing the crap that was the sidebar.
The original code comes from the first example at;
http://www.google.com/apis/maps/documentation/

I have copied this info from;
http://econym.org.uk/gmap/basic3.htm

"      function createMarker(point,name,html) {
        var marker = new GMarker(point);
        GEvent.addListener(marker, "click", function() {
          marker.openInfoWindowHtml(html);
        });

      GDownloadUrl("example.xml", function(doc) {
        var xmlDoc = GXml.parse(doc);
        var markers = xmlDoc.documentElement.getElementsByTagName
("marker");

        for (var i = 0; i < markers.length; i++) {
          // obtain the attribues of each marker
          var lat = parseFloat(markers[i].getAttribute("lat"));
          var lng = parseFloat(markers[i].getAttribute("lng"));
          var point = new GLatLng(lat,lng);
          var html = markers[i].getAttribute("html");
          // create the marker
          var marker = createMarker(point,html);
          map.addOverlay(marker);"

The stuff pointing to a label has been removed since that was for the
sidebar.

Later i will add custom markers in this way;
http://econym.org.uk/gmap/example_custom.htm



As you can see, the map doesnt load after i have added the xml loading/
creating marker stuff.
So i must have missed something.
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"Google Maps API" 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-API?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to