cocoon-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Juan J. Merelo" <jj.mer...@civista.com>
Subject Matching <!DOCTYPE ...>?
Date Fri, 03 Nov 2000 04:33:27 GMT
Hi,
    I am trying to <util:include> an XHTML file which has a <!DOCTYPE
declaration at the beginning>, using this XML
--
<?cocoon-process type="xsp"?>
<?cocoon-process type="xslt"?>
<?xml-stylesheet href="sample.xsl" type="text/xsl"?>

<xsp:page language="java" xmlns:util="http://www.apache.org/1999/XSP/Util"
  xmlns:xsp="http://www.apache.org/1999/XSP/Core">
<page title="Tidificando">
 <util:include-file name="c:/temp/kk2.html"/>
</page>
</xsp:page>
--
kk2.html includes this as first line:
--
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN"
"http://www.w3.org/TR/REC-html40/strict.dtd">
--

There's no problem if I take that line out, but if I include it, I get this
error:
org.xml.sax.SAXParseException: The declaration for the entity "ContentType"
must end with '>'.
	at
org.apache.cocoon.parser.AbstractParser.fatalError(AbstractParser.java:105)

---
There's no way to include that DTD. I have tried matching it with
match="processing-instruction()", but it does not seem to be matched. Here's
the stylesheet I use:

<?xml version="1.0"?>

<xsl:stylesheet version="1.0"
   xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
   xmlns:xsp="http://www.apache.org/1999/XSP/Core"
>

<xsl:template match="xsp:page/page">
 <xsl:apply-templates />
</xsl:template>

<xsl:template match="processing-instruction()">
</xsl:template>

<xsl:template match="html">
<html>
 <xsl:copy-of select="node()"/>
</html>
</xsl:template>

</xsl:stylesheet>
--
Nothing could be simpler. I also get an error without the stylesheet. Any
idea?

J

-

Name: Juan J. Merelo
Title: Consultant
Civista
Telephone:   +44 (0) 20 84086.....
Mobile:        +34 627 397239
Facsimile:    +44 (0) 20 84086399
Email:jj.merelo@civista.com
http://www.civista.com

Services and Applications for a Wireless World
This e-mail and the information that it contains may be confidential and
protected by law and is for access by the intended recipient only. Any
liability (in negligence or otherwise) arising from any third party acting,
or refraining from acting, on any information contained in this e-mail is
hereby excluded. If you are not the intended recipient, please notify the
sender immediately and do not disclose the contents to any other person, use
it for any purpose, or store or copy the information in any medium.
Copyright in this e-mail and any attachments belongs to Civista Limited
and/or its subsidiary companies.
While this message is virus checked, Civista can not be held responsible for
its integrity.





Mime
View raw message