Hello Joel,

yes, we had this issue already on the mailing lists, but IIRC no solution was provided. Is following simple solution an option for you?

Add a <map:transform src="copy.xsl"/> to the pipeline.
The copy.xsl looks like following:

<xsl:template match="/">
  <xsl:copy-of select="/"/>

There is no default for matcher for comment(), so these SAX events should not be let through.


Joel Ekstrand wrote:
I have problems reading xhtml-files. The problem occours when I have a DTD specified. I tried this just to see what is going on:
<map:match pattern="**.xml">
<map:generate src="documents/{1}.html" />
<map:serialize type="xml"/>
I then request test.xml and I have a file like this in documents/test.html:
<?xml version="1.0" ?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd";>
<html xmlns="http://www.w3.org/TR/REC-html40";>
<body >
The generated output is:
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd";<!--================== Imported Names ====================================--><!-- media type, as per [RFC2045] --><!-- comma-separated list of media types, as per [RFC2045] --><!-- a character
and so on. All the comments in the DTD is included. And its one > to much. So the output is not accepted as xml.
Am I doing something wrong? Or is it a bug? I am a newbie on cocoon...

To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to