prev next prev next
Course navigation
Lesson 4   HTML limitations
Objective
  Describe the limitations of HTML.
The primary limitation of HTML is that HTML tags do not describe the meaning of the data included in an HTML document.
HTML uses a fixed, predefined tag set that specifies formatting and instructs a browser how to render data included in these tags. But the tags do not convey the meaning or semantics of data contained in the tags. In many cases, the meaning of the data included in a document is critical. XML is designed to overcome this and other limitations of HTML.
hacking, Form, cloud computing

portal design, ad hoc, Cisco
    The Advent of XML
Unlike HTML tags, XML tags do convey meaning. XML tags make searching for information more efficient. For example, to describe the movie Titanic we may use the following set of elements:
<FILM>
 <TITLE> Titanic </TITLE>
 <PRODUCER>James Cameron, Jon Landau</PRODUCER>
 <DIRECTOR>James Cameron</DIRECTOR>
  <SCREENWRITER>James Cameron</SCREENWRITER>
 <DISTRIBUTOR>Paramount</DISTRIBUTOR>
 <BOX-OFFICE>$376,270,721</BOX-OFFICE>
</FILM>
    Titanic as the title
When these elements are included as part of a document on a server, a search program would have no problem identifying Titanic as the title of a film. In addition, the computer search program would be able to identify other attributes of the Titanic film such as its producer, director, and so on.
  Structural definition
XML elements not only convey the meaning of data, but also enforce a well-defined structure for the data. XML elements may also contain other elements and a tree-like structure for this document is easily identified. The structural definition of an HTML document is not as easily discernable.
In the above example, the XML <FILM> element contains
  1. <TITLE>,
  2. <PRODUCER>,
  3. <DIRECTOR>,
  4. <SCREENWRITER>,
  5. <DISTRIBUTOR>, and
  6. <BOX-OFFICE> elements.

Each of these elements, in turn, contains data.
The well-defined structure of an XML document is important when you use XML parsersas you will see later in the course.
  The next lesson defines XML.
  MetaLanguages Markup Quiz
Click the Quiz button to test your understanding of metalanguages, markup, and HTML limitations.
MetaLanguages Markup Quiz
Course navigation