XHTML Upgrade
This site will be upgraded to XHTML (eXtensible HyperText Markup Language) in the future in order to ensure rigorous adherence to best practice for HTML tags and the highest level of browser compatibility. HTML code was originally strict in definition, but various browser interpretations of the code have allowed a range of poor HTML practice.
XML (eXtensible Markup Language) is not itself a replacement for HTML. Rather it is a mark-up language protocol, though it in fact uses the same triangle brackets for delineating tags as HTML. XML is very demanding in its requirements for strict application of mark-up rules. Unlike HTML, there are no predefined tags: instead tags are defined in a DTD (Document Type Definition) that can be included in the XML document or stored separately.
HTML has been fully re-created within the XML protocol, creating XHTML. XHTML is "a stricter and cleaner version of HTML 4.01" (w3schools 2013). Converting an HTML site to XHTML requires a number of steps:
- Commence pages with an XML declaration that identifies the document as an XML file, and the DTD to be used. For consistency this site will use a standard document hosted by the W3C organisation.
- An XML document must have a root element that contains all other elements
- Ensure required tags such as <html>, <head> and <body> are used
- Check the existing code to ensure all tags are in lower case (XML is case sensitive)
- Check the existing code to ensure all nesting of tags is done correctly
- Ensure that all tags have correct pairs (<b> </b>) and "empty" tags are properly written (<hr/>).
- All attribute values must be enclosed in single or double quotes (for instance the URL of a link target must be in quotes)
- To use a character reserved by XML as a tag, a strict "entity reference" must be used (" to represent a ").
- Check multiple spaces: HTML truncates repeated spaces to one space, XML does not.
There are possible disadvantages. XML is rigorous so if errors exist browsers will not brush over the errors as they might have with HTML. Converting existing poorly written code can be a complex task. XHTML has had wide-spread acceptance, but may still be replaced in the future by an alternate protocol such as HTML 5.
XML does have the advantage that it is recommended by W3C (w3schools 2013). In addition XML has much wider uses than simply re-creating HTML, and business data encoded with XML is software and platform independent and hence more adaptable to changing technology (Microsoft n.d.). XML is also a protocol that can unify the coding of different types of data.
References
Felke-Morris, T. (2011). Web Development and Design Foundations with XHTML. Boston: Addison-Wesley.
Microsoft (n.d.) XML: What's it all about? Retrieved from
http://office.microsoft.com/en-au/word-help/xml-what-s-it-all-about-RZ001130477.aspx?section=1 Retrieved 2/6/2013
Pelz-Sharpe, A. (2010) What is XML and Why Should Companies Use It?, Inc. Retrieved from http://www.inc.com/guides/2010/04/why-companies-should-use-xml.html Retrieved 2/6/2013
W3C (2002) XHTML™ 1.0 The Extensible HyperText Markup Language (Second Edition). Retrieved from http://www.w3.org/TR/xhtml1/Cover.html#toc Retrieved 2/6/2013
w3schools 2013 (n.d.) XML Tutorial. Retrieved from http://www.w3schools.com/xml/default.asp Retrieved 2/6/2013
XML Simplified. Retrieved from http://blog.bounceweb.com/xml-simplified-understanding-the-structure/ Retrieved 2/6/2013
Six String Theory