HTML vs. XHTML

Abstract

The Internet technology made it possible for computers to connect to each other and made it also possible for these computers to transmit, and receive data and information back and forth. Over a short period of time the web content grown beyond the simple text documents to information that carry images, videos, audio, and other features that went beyond users imagination. However, with the advanced technology around the web content, the web is fundamentally a text-based technology that is built with text that encoded with HTML. Many devices and computers can access such web content through what’s technically called a user-agent or a browser. The main purpose of such software is to be able to render web documents by interpreting the HTML content. A browser or user-agent is also called the client since the service request comes from the browser to the host server to prepare the page and send the service to the client to render the web content.

Schultz and Cook (2007) defined the HTML (Hypertext Mark-up Language) as a computer coding language that can convert normal text to an active text that can be used on the web, and be able to be rendered through the browser software. Without some language structure that imposed to the plain text, the text would run together without distinguish one string from another. HTML structures encoded markers called tags that are embedded within the plain text document to make it possible for the browser to read these tags, and translate in a way that makes the plain text render in different shapes and different looks. The client will receive these tags and the browser will be able to distinct these tags from the text that should be render on the client browser.

Adding to the simplicity and the flexibility of the HTML language, it’s also free open standard that are not owned or controlled by any company or individual. You don’t need to have a license to use the language to build your web site, and no special software required to author your own HTML documents. However, certain rules has to be followed to make sure that the web content will be rendered correctly, and for that reason these rules are maintained by the World Wide Web Consortium (W3C). W3C is a non-profit organization that defines most of the open technical standards that are used by the web technologies. The good news about these standards is to ensure that the software that interprets those languages contain the same set of rules that are agreed-upon.

The Evolution of HTML

HTML invention was based on the Standard Generalized Mark-up Language (SGML) that was created specifically for making up documents to be used on the World Wide Web. From the early 1990 until now; HTML went through different versions and enhancements with new features that can follow certain standards. With the early ages of web development, competing browsers were supporting different features that can include non-standard features which created a lot of troubles for the web development that were leading authors to develop different versions of sites to work with different browsers. Today such problem is eliminated, and the vendors of different browsers are following certain standard that can be compliant with the standard languages are used in creating web contents (Schultz and Cook, 2007).

In a short period of time the HTML languages went through different versions from HTML 1.0 to HTML 4.01 in 1999. This version was called the final version for a long time, however W3C has starting drafting a new specification for HTML 5; and it’s in the early stages of the development and nothing has been published about such version. While HTML still exist in many web content online, a new language called extensible HTML (XHTML) created in 2000 that is called the new wave of the future. XHTML is advanced language that allows the author of the web content to customize its own tags. XHTML is similar to HTML 4.01 to some extent where a few more rules are dictating how it must be written. The current versions exist for XHML are ver. 1.0 and 1.1 and XHTML ver. 2.0 still under the development (Schultz and Cook, 2007).

HTML vs. XHTML

Schultz and Cook (2007) explained that with the different versions of the HTML, the language was lacking the proper means of influencing the display of content. Web designers were forced to adapt work around the languages to take advantage of the way browsers displays contents. With a new technology such as Cascading Style Sheets (CSS); HTML document was visually presented better while leaving the mark-up clean and meaningful. This CSS can add an attractive layer of visual design without negatively impacting the mark-up language, and allows the web designer to separate the content layer from the presentation layers. Like HTML; CSS is an open standard that is obtained by the W3C.

White and Karow (2004) explained that HTML and XML or XHTML (Extensible Hypertext Mark-up Language) is the first specification that was created to be the next generation of mark-up language. XHTML standard was influenced by the standard of HTML and XML, and was design to be used in XML-Complaint environment, and yet compliant with the standard rules of the HTML 4.01 user agents or browsers. There were great expectations of having a mix of HTML 4.0 and CSS to have a better version of HTML to continue its journey. However that Journey was cut short after the HTML was replaced with XHTML.

Lloyd (2008) stated that the argument about using HTML and XHTML still going these days and a lot of web authors are leaning toward using the XHTML since it’s a newer implementation of HTML and for that only reason it’s better option for them to use it. It’s imperative to be clear about using either in your design as long as the web author are using the HTML standards with the appropriate doctype, and the HTML that is used is valid for that doctype.

Pemberton (2004) was trying to answer the very important questions about the HTML and the XHTML, and the following are some of these questions and the brief answers for these questions:

 

  • Why XHTML is needed if HTML still around and can do the job? With the success story of the HTML, when the XML was introduced, a new version of HTML was needed to implement the XML within the HTML document, and that’s why XHTML was introduced to the web world.
  • What are benefits of using XHTML over HTML? As more tools are introduced in the web design that implement XML, and XSLT for transforming documents, the benefits of using XHTML start to be more obvious to be used.

 

  • Why we can use the XML declaration on top of existing HTML documents?  Since HTML doesn’t support the XML format, changes have to be made to make the document proper XML and to accept the XML format.

Lenssen (2002) explained that changes needed to create new standard for designing a web document and some of these technical reasons are:

 

  • Many interpreters are around today to support the XML documents.
  • All the mechanisms that are needed to access and convert XML documents are exist as a good features of XML document and some of these mechanism are XML DOM and XMP XPath.
  • Another important point is that XHTML is more flexible to work within a team, since different layers of the document can be built in parallel.

 Lenssen (2002) also suggested that with the argument between using HTML vs. using XHTML the winner is the web author, because HTML and XHTML provide two equal powerful tools to be used wherever you can to get the job done. Both tools are available to use either of them based on your needs, and what works best for your environment. He also suggested that if the web author has no reference to any of these two powerful tools, it’s better to choose the XHTML since it’s the most recent standard that was approved by W3C.

Meiert (2008) argued that with the plenty of discussions about the right document type, most of the discussions are missing the main point, and often deal with irrelevant details of the discussions. The main factor that can be the decisive factor in all of these discussions should be the performance. Performance of the document type means the load time that will take of any document to land on the user agent. With the XHTML documents the file size is bigger with about 5% – 10% of the file size of the HTML for the same document. The reason behind that are the extra tags (Optional tags in HTML) that are used by the XHTML that can increase the file size overhead with at least 400 bytes per document. By using HTML document instead of the XHTML document not only web authors are gaining document performance, but also avoiding the problem with MIME type.

Conclusion

HTML is a language used to structure hyper-linking content that is at the core of most web pages. XHTML (extensible HTML) is the latest version of Hypertext mark-up language. Technically speaking, XHTML is HTML reformed as XML, and it’s more modern version of HTML. Both HTML and XHTML are a web standard for building a web contents. By utilizing the web standard, web authors can ensure the universal compatibility, and the flexibility of the web contents. Both HTML and XHTML are powerful tools that can give you the flexibility to choose, and to create the design that can fit your needs. Without any doubts, if you have no reference to any of these languages, XHTML is the best choice, since it supports both standards of the HTML and the XML.

References

Greer, C. & Raggett, D. (2000) Beginning XHTML. 2nd ed.Birmingham: Wrox Press Ltd.

Lenssen, P. (2002) HTML vs. XHTML [Online]. Available from: http://www.outer-court.com/tech/tutorials/html-vs-xhtml/ (Accessed: 7 February 2010).

Lloyd, I.(2008) The Ultimate HTML Reference. 1st ed. Collingwood: SitePoint Pt Ltd.

Meiert, J. (2008) HTML vs. XHTML: Why HTML Wins [Online]. Available from: http://meiert.com/en/blog/20081219/html-vs-xhtml/ (Accessed: 7 February 2010).

Pemberton, S. (2004) HTML and XHTML Frequently Answered Questions [Online]. Available from: http://www.w3.org/MarkUp/2004/xhtml-faq (Accessed: 7 February 2010).

Schultz, D. & Cook, C. (2007) Beginning HTML with CSS and XHTML. 2nd ed.California: Apress.

White, C. & Karow, B. (2004) HTML, XHTML, and CSS Bible. 3rd ed.

Indianapolis: Wiley Publishing, Inc.

 

 

 

 

 

 

 

 

Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: