|
|
|
|
Clearly, it would be useful to specify the DTD for an XML document externally
from the document itself. You can do this by specifying the following in
the
Where the <?xml version="1.0" encoding="UTF-8"?> <!ELEMENT memo (from, to+, body, priority?)> <!ELEMENT from (#PCDATA)> <!ELEMENT to (name | department)> <!ELEMENT name (#PCDATA)> <!ELEMENT department (#PCDATA)> <!ELEMENT body (#PCDATA)> <!ELEMENT priority (high | medium | low)> <!ELEMENT high EMPTY> <!ELEMENT medium EMPTY> <!ELEMENT low EMPTY> Again, if you want to see how your browser renders the above XML document, click here. |
| The page was last updated February 19, 2008 |