
Extensible Markup Language (XML) is a group of programming conventions used for the encoding of structured documents. A structured document contains information elements that include content and the context in which such information elements are used. XML defines the method in which these elements are provided and how they fit in a structured hierarchy. In comparison to HTML, XML does not have rigid tag semantics or tag set. XML allows new tags to be incorporated as and when required, based on changing technology and stylesheets. XML primarily came into being to utilize content rich structured documents on the internet.
The World Wide Web Consortium (W3C) has classified XML standards via the XML 1.0 Specification; it is a free for use open standard. Other XML standards introduced after the publication of the XML 1.0 specification include XML Base, XML Namespace, XML Information Set, XSLT, XML Signature, XML Encryption and so on. A large number of XML centric languages such as Atom, XHTML, SOAP and RSS are in use today. Various office based tools and applications used XML formats to produce content rich documents.
XML syntax guidelines
XML syntax adheres to very simple and clear guidelines. Some of the basic guidelines are as follows:
Root element
All XML documents must have one element defined as the root element, which serves as the parent for all other elements in the XML document.
Closing tag
All XML tags, with the exception of the XML declaration, must have a closing tag.
Case sensitive
XML tags are case-sensitive; the start and end XML tags must be of the same case.
Nested XML elements
XML elements must be properly nested. If an element is started within another element, it should be ended within the same element as well.
XML attribute values
The attribute value pertaining to a XML element must always be stated within quotes.
XML elements
An XML element is any logical component enclosed within a start and end tag. An element can have other elements layered within it, regular text, or both. XML element names can have letters, numbers and other characters; however they cannot begin with a number or punctuation mark, or with the letters “xml”, and should not contain spaces. XML elements can have attributes, which is a name/value pair, within a start and end tag. Attributes are used to provide additional information about an XML element. These attributes must always be mentioned within quotation marks. An XML element must not have two attributes with the same name.
