Jump to content

Simple XML

From Wikipedia, the free encyclopedia
This is an old revision of this page, as edited by Codebytez (talk | contribs) at 21:02, 21 March 2007 (Initial cut). The present address (URL) is a permanent link to this revision, which may differ significantly from the current revision.
(diff) ← Previous revision | Latest revision (diff) | Newer revision → (diff)

Simple XML

Simple XML is a variation of XML containing only elements. All attributes are converted into elements. Not having attributes or other xml elements such as the XML declaration / DTDs allows the use of simple and fast parsers. This format is also compatible with mainstream XML parsers.

for example:

 <Agenda>
   <type>gardening</type>
   <Activity>
     <type>Watering</type>
     <golf-course>
        
     </golf-course>
     <yard>
       
   </Activity>
   <Activity> 
     <type>cooking</type>
     <lunch> 
       
   </Activity>
 </Agenda>

would represent:

 <?xml version="1.0" encoding="UTF-8"?
 <Agenda type="gardening">
   <Activity type="Watering">
     <golf-course time="6:00"/>
     <yard time="7:00"/>
   </Activity>
   <Activity type="cooking">
     <lunch time="12:00"/>
   </Activity>
 </Agenda>