Welcome, Guest
Username: Password: Remember me

TOPIC: Wrong KML structure

Wrong KML structure 10 years 1 week ago #7759

  • igorsd
  • igorsd's Avatar
  • Offline
Hello. I am trying to display KML overlay over google maps and found out that "<Style>" tags are located inside "<Folder>" tag.
Current kml structure:
<Folder>
<styles>
<document>
<name>NewUserMap</name>
...
</Document>
</Folder>

Google maps API seems to be ignoring "<styles>" while located inside <Folder>.
Moving <styles> to <document> tag resolves this problem, so the correct structure should be:
<Folder>
<document>
<styles>
<name>NewUserMap</name>
...
</Document>
</Folder>
While both versions seem to be correct according to developers.google.com/kml/documentation/...nce#contained-by_184 , only the second one is displayed correctly by Maps API. Google Earth, btw, displays both versions correctly.
The administrator has disabled public write access.
SCROLL TO TOP