Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.
Comment: Migrated to Confluence 5.3

Some characters cannot directly expressed in XML. They need to be expressed in a special way using XML's escape charter &. They are:

CharacterXML Representation
<&lt;
&&amp;
>&gt;

There are two more characters that may need "escaping". Details can be found on Wikipedia.

One example for is mechanism is the DisplayArtistName for the collaboration George Benson & Al Jarreau. This needs expressing in XML as

Code Block
languagehtml/xml
<DisplayArtistName>George Benson &amp; Al Jarreau</DisplayArtistName> 
Info

Someone receiving  such information must "un-escape" the &amp; to & – otherwise, if he ingests the name as is into his database and if he then creates a new XML message, he may end up sending:

Code Block
languagehtml/xml
<DisplayArtistName>George Benson &amp;amp; Al Jarreau</DisplayArtistName> 

which is then displayed as "George Benson &amp; Al Jarreau"...