You are viewing a plain text version of this content. The canonical link for it is here.
Posted to j-dev@xerces.apache.org by "RAJARAJAN.A.L" <ra...@comneti.com> on 2001/01/11 09:24:10 UTC

XSL Error

Hi,
    When I try to view my xml document in Internet Explorer, then an error is shown as

The XML page cannot be displayed 
Cannot view XML input using XSL style sheet. Please correct the error and then click the Refresh button, or try again later. 


--------------------------------------------------------------------------------

Reference to undeclared namespace prefix: 'JavaXML'. Line 4, Position 1 

<JavaXML:Book xmlns:JavaXML="http://www.oreilly.com/catalog/JavaXML/">
^
My xml code is as

<?xml version="1.0"?>
<?xml-stylesheet href="JavaXm.xsl" type="text/xsl"?>
<!DOCTYPE JavaXML:Book SYSTEM "JavaXml.dtd">
<JavaXML:Book xmlns:JavaXML="http://www.oreilly.com/catalog/JavaXML/">
   <JavaXML:Title>Java and XML</JavaXML:Title>
       <JavaXML:Contents>
            .......
            .......
            .......
My xsl code is as

<?xml version="1.0">
<xsl:stylesheet xmlns:xsl="http://www.w3.org/TR/WD-xsl"
                xmlns:JavaXML="http://www.oreilly.com/catalog/JavaXML/"
                version="1.0"
>
<xsl:template match="JavaXML:Book">
    <html>
        <body>
            HelloWorld!
        </body>
    </html>
</xsl:template>
</xsl:stylesheet>

Can anyone help.

Regards,
Rajan.