11.07.2015 Views

webMathematica™ Wolfram - Wolfram Research

webMathematica™ Wolfram - Wolfram Research

webMathematica™ Wolfram - Wolfram Research

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

webMathematica User Guide 69A sample XML document is shown below.A New Kind of ScienceStephen <strong>Wolfram</strong>The Lord of the RingsJ.R.R. TolkienThe example above shows a data format for a library. The library contains books and each bookhas a title and an author. This shows how XML is suitable for structured data. In addition, youcan see how XML looks a little like HTML, except that the tags (words bracketed by '')are not restricted to a fixed set since new tags, that are suitable for a particular application, canbe introduced. Unlike HTML, the format of XML is stricter with a valid XML document beingrequired to follow rules that do not apply to HTML. This is demonstrated in the next section.XML ComplianceOne issue with XML is that documents must be wellformed, following the rules of XML. Somebasic examples of compliance are described in this section.An XML document must include a header. For example, it must start with something like thefollowing.Empty elements must either have an end tag, or the start tag must end with />. Thus, thefollowing is legal.However, this is not legal.For nonempty tags, the end tag is required. Thus, the following is legal.Here is a paragraph.Here is another.

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!