[XSL-LIST Mailing List Archive Home]
[By Thread]
[By Date]
Re: How to embed HTML in XML
Subject: Re: How to embed HTML in XML From: Mike Brown <mike@xxxxxxxx> Date: Tue, 1 Aug 2000 13:56:00 -0700 (PDT) |
Amit Aggarwal wrote: > I want to embed HTML into an XML.The problem which I am facing is that the > XSLT processor gives errors for HTML tags and forces me to define them in > the DTD. > > Is there some simple way in which I can make the XSLT processor to ignore > the HTML tags and I dont have to define it in the DTD. HTML and XML do not mix. You can pretend your HTML is one character data section, copy it to a text node, and rely on disable-output-escaping functionality in XSLT to work with it, but ultimately you may find it easier to make your HTML well-formed XML (XHTML; see the spec at w3.org) and work with that in your XML instead. As for validation, an XML parser is feeding to the XSL processor some information about the logical contents of the XML document. It is possible that you are invoking an XSL processor and it is invoking an XML parser for you. The XSL processor does not know about the DTD. You should check the documentation for your XSL processor and/or XML parser to figure out how to get it to parse without validating. You can't half-validate, though. If you're validating, you must declare all the elements that are used in the document. No way around that. -Mike XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list
Current Thread |
---|
|
<- Previous | Index | Next -> |
---|---|---|
How to embed HTML in XML, Amit Aggarwal | Thread | Re: How to embed HTML in XML, Vernon_Imrich |
RE: MSXML Whitespace handling, Andrew Kimball | Date | Re: Saxon VS XT, David_Marston |
Month |