HTML and the World Wide Web are everywhere. As an example of their
ubiquity, I'm going to Central America for Easter this year, and if I
want to, I'll be able to surf the Web, read my e-mail, and even do
online banking from Internet cafés in Antigua Guatemala and
Belize City. (I don't intend to, however, since doing so would take
time away from a date I have with a palm tree and a rum-filled coconut.)
And yet, despite the omnipresence and popularity of HTML, it is
severely limited in what it can do. It's fine for disseminating
informal documents, but HTML now is being used to do things it was
never designed for. Trying to design heavy-duty, flexible,
interoperable data systems from HTML is like trying to build an
aircraft carrier with hacksaws and soldering irons: the tools
(HTML and HTTP) just aren't up to the job.
The good news is that many of the limitations of HTML have been
overcome in XML, the Extensible Markup Language. XML is easily
comprehensible to anyone who understands HTML, but it is much more
powerful. More than just a markup language, XML is a
metalanguage -- a language used to define new markup
languages. With XML, you can create a language crafted specifically for
your application or domain.
XML will complement, rather than replace, HTML. Whereas HTML is used
for formatting and displaying data, XML represents the contextual
meaning of the data.
This article will present the history of markup languages and how XML
came to be. We'll look at sample data in HTML and move gradually
into XML, demonstrating why it provides a superior way to represent
data. We'll explore the reasons you might need to invent a
custom markup language, and I'll teach you how to do it.
We'll cover the basics of XML notation, and how to
display XML with two different sorts of style languages. Then, we'll
dive into the Document Object Model, a powerful tool for manipulating
documents as objects (or manipulating object structures as documents,
depending upon how you look at it). We'll go over how to write Java
programs that extract information from XML documents, with a pointer to
a free program useful for experimenting with these new concepts.
Finally, we'll take a look at an Internet company that's basing its
core technology strategy on XML and Java.
Is XML for you?