Chapter 10. XML
The Extensible Markup Language (XML) is a
document-processing standard that is an official recommendation of
the World Wide Web Consortium (W3C), the same group responsible for
overseeing the HTML standard. Many expect XML and its sibling
technologies to become the markup language of choice for dynamically
generated content, including nonstatic web pages. Many companies are
already integrating XML support into their products.
XML is actually a simplified form of Standard Generalized
Markup Language (SGML), an international documentation
standard that has existed since the 1980s. However, SGML is extremely
complex, especially for the Web. Much of the credit for
XML's creation can be attributed to Jon Bosak of Sun
Microsystems, Inc., who started the W3C working group responsible for
scaling down SGML to a form more suitable for the Internet.
Put succinctly, XML is a metalanguage that
allows you to create and format your own document markups. With HTML,
existing markup is static: <HEAD> and
<BODY>, for example, are tightly integrated
into the HTML standard and cannot be changed or extended. XML, on the
other hand, allows you to create your own markup tags and configure
each to your liking—for example,
<HeadingA>,
<Sidebar>, <Quote>,
or <ReallyWildFont>. Each of these elements
can be defined through your own document type
definitions and stylesheets and
applied to one or more XML documents. XML schemas provide another way
to define elements. Thus, it is important to realize that there are
no correct tags for an XML document, except those you define
yourself.
While many XML applications currently support Cascading
Style Sheets (CSS), a more extensible style sheet
specification exists, called the Extensible Stylesheet
Language (XSL). With XSL, you ensure that XML documents
are formatted the same way no matter which application or platform
they appear on.
XSL consists of two parts: XSLT
(transformations) and XSL-FO
(formatting objects). Transformations, as
discussed in this book, allow you to work with XSLT and convert XML
documents to other formats such as HTML. Formatting objects is
described briefly later in this chapter.
This chapter offers a quick overview of XML, as well as some sample
applications that allow you to get started in coding. We
won't cover everything about XML. Some XML-related
specifications are still in flux as this book goes to print. However,
after reading this book, we hope that the components that make up XML
will seem a little less foreign.
 |