An Easy XML Structure Outlined
View PDF | Print View
by: michaeldupre
Total views: 71
Word Count: 281
Date: Wed, 13 Jul 2011 Time: 3:29 AM
Hello there, my name is Michael Dupre. You are welcome to my '5 minute XML' series just where I present you with regular bite size tutorials.
This next sample is a three line snippet exhibiting a well made XML file,
This example shows a pretty simple correctly formed XML file. It can also be entered using a straightforward text editor as well as one of the XML editors available nowadays. When composing the document away, the file-name ought to end with .xml. As an example: “human.xml” or “yourFileName.xml”.
[human]
[gender]
male
[/gender]
[born]
18 July 1990
[/born]
[hairColour]
Blonde
[/hairColour]
[/human]
Inside the illustration mentioned above, the [human] ... [/human] element has 3 other elements and each of these incorporate textual content. Because of the three elements are generally amongst the opening and closing human element tags it indicates that possibly they are 'child elements' of human.
These child elements provide us with certain specifics of the parent element. In this case this tells us that this human is "male", was born "18 July 1990" and has "Blonde" hair.
XML allows us to shape our data collections from a logical, hierarchy that makes sense. The particular content offered by the child elements from the preceding sample can certainly be made available using attributes. I'll be talking about these in my next tutorial.
A great deal of information is available on XML for individuals that would want to uncover more. For the definitive guide, visit www.W3.org.
I hope the above is useful to someone out there. More content will be on its way shortly.
About the Author
Michael Dupre is actually a most recognized authority in XML coding and XML standards and possesses in excess of 15 years of working in the web standards and usability fields together with within XML markup languages. Which is precisely why he is an expert with XML Editor and has practical know how with XML Schema Editor.