S
Simon Brooke
I maintain a DTD which is used to specify XML documents which are mostly
marked up in the dialect specified by the DTD ('ADL'), but in which there
are three elements whose contents are intended to be arbitrary XHTML 1.1.
Currently I've declared these as #PCDATA and simply ignore the parse
errors this causes, but this isn't very good and I'm not proud of it.
Is there a syntax for saying 'this element contains markup from this
other namespace' (I assume not, since SGML doesn't know about XML
namespaces?)? Otherwise, is there a syntax for saying 'this element
contains arbitrary markup'?
I know that I could include the XHTML DTD into my DTD but I'd prefer not
to do this as I'd prefer to keep the namespaces separate - to be able to
do:
<adl:topmatter>
<xhtml:div class="top">
<xhtml>This appears at the top of every page</xhtml>
</xhtml:div>
</adl:topmatter>
I know also that I really ought to move to an XSD schema, but I find them
just too prolix and awkward to work with!
marked up in the dialect specified by the DTD ('ADL'), but in which there
are three elements whose contents are intended to be arbitrary XHTML 1.1.
Currently I've declared these as #PCDATA and simply ignore the parse
errors this causes, but this isn't very good and I'm not proud of it.
Is there a syntax for saying 'this element contains markup from this
other namespace' (I assume not, since SGML doesn't know about XML
namespaces?)? Otherwise, is there a syntax for saying 'this element
contains arbitrary markup'?
I know that I could include the XHTML DTD into my DTD but I'd prefer not
to do this as I'd prefer to keep the namespaces separate - to be able to
do:
<adl:topmatter>
<xhtml:div class="top">
<xhtml>This appears at the top of every page</xhtml>
</xhtml:div>
</adl:topmatter>
I know also that I really ought to move to an XSD schema, but I find them
just too prolix and awkward to work with!