[Mass-Market-GEO] kml:description content model

Rushforth, Peter prushfor at NRCan.gc.ca
Wed Aug 27 14:14:57 EDT 2008


Hi,

In the KML 2.2 schema, the kml:description element is of type xs:string.

You can put html or xhtml markup in the kml:description element, and earth browsers
will display it formatted according to markup.

In order to put (ill-formed) html markup in the description element, you need to enclose it
in a CDATA section.

>From the XML spec:

Definition: CDATA sections may occur anywhere character data may occur; 
they are used to escape blocks of text containing characters which would 
otherwise be recognized as markup.

Shouldn't the type of kml:description be xs:anyType, which still would allow
string values, but would also permit well-formed markup without having
to escape the markup or enclose it in CDATA?

Maybe I'm wrong somewhere here.

Cheers,

Peter Rushforth
Technology Advisor / Conseiller technique
GeoConnections / GéoConnexions
650-615 Booth St. / rue Booth
Ottawa ON K1A 0E9
E-mail / Courriel: Peter.Rushforth at NRCan.gc.ca 
Phone / Télephone: (613) 943-0784 
Fax / telecopier:  (613) 947-2410



More information about the Mass-Market-GEO mailing list