It all gets a bit messy because of the way that characters like <, > and
" are treated. You might possibly find it easier to write your XML like
this:

<marker lat="50.80901" lng="-2.738889" label="BARNFLEET, BEAMINSTER"
icontype="0">
  <html><![CDATA[
      <strong>BARNFLEET, BEAMINSTER</strong><br>
      <a href="barnfleet.html">Click Here</a><br>
      Brief bit of info
  ]]></html>
</marker>

Everything between the <![CDATA[ and the ]]> is treated as "character
data", where those awkward characters are not treated as special.

However, this makes <html> become a child of <marker> instead of an
attribute, so you can't use getAttribute(), you have to do this:

  var html = GXml.value(markers[i].getElementsByTagName("html")[0]);

Don't forget that [0] at the end. Lots of people seem to miss it.


If you write your XML like that, then you can develop and test your
"html" outside your map, then paste it into your XML when you've got it
behaving exactly the way you want.

-- 
Mike Williams
http://econym.org.uk/gmap



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