OASIS Mailing List ArchivesView the OASIS mailing list archive below
or browse/search using MarkMail.

 


Help: OASIS Mailing Lists Help | MarkMail Help

docbook-apps message

[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index] | [List Home]


Subject: Re: [docbook-apps] Element type "xsl:stylesheet" must be declared.


Bob, thanks.
You suggestion is spot-on. I was running java 1.4. Adding the java.endorsed.dirs option fixed the problem. The complete command now being:

java -cp C:\dbk\fop-0.93\build\fop.jar;
         C:\dbk\fop-0.93\lib\xalan-2.7.0.jar;
         C:\dbk\fop-0.93\lib\xml-apis-1.3.02.jar;
         C:\dbk\fop-0.93\lib\xercesImpl-2.7.1.jar;
         C:\dbk\docbook-xsl-1.70.1\extensions\xalan27.jar
-Djava.endorsed.dirs="C:\dbk\fop-0.93\lib"
org.apache.xalan.xslt.Process
-in sample.xml
-out "sample.html"
-xsl "C:\dbk\docbook-xsl-1.70.1\html\docbook.xsl"
-param use.extensions 1

Thanks again!

Mike.

----- Original Message ----
From: Bob Stayton <bobs@sagehill.net>
To: Mike M <spmikedev@yahoo.com>; docbook-apps@lists.oasis-open.org
Sent: Wednesday, April 4, 2007 9:02:59 PM
Subject: Re: [docbook-apps] [SPAM] Element type "xsl:stylesheet" must be declared.

I'm not able to duplicate this error using the setup and command you 
specify.  I'm running java version "1.5.0_05".

That error message indicates that the Xerces parser being used is 
initiating validation of the autoidx.xsl file because it sees a DOCTYPE 
declaration.  The DOCTYPE is there to declare entities, and not to indicate 
a DTD for validation.  It should not be trying to validate.

It is possible you aren't getting the Xalan you think you are getting 
because of Java's endorsement feature.  See:

http://www.sagehill.net/docbookxsl/InstallingAProcessor.html#InstallXalan

Bob Stayton
Sagehill Enterprises
DocBook Consulting
bobs@sagehill.net


----- Original Message ----- 
From: "Mike M" <spmikedev@yahoo.com>
To: <docbook-apps@lists.oasis-open.org>
Sent: Tuesday, April 03, 2007 11:55 AM
Subject: [docbook-apps] [SPAM] Element type "xsl:stylesheet" must be 
declared.


> Hello all,
>
> I am attempting to process a docbook document using Xalan and the latest 
> stylesheets (1.72.0), but I am receiving a stream of errors:
>
> [Error] autoidx.xsl:10:31: Element type "xsl:stylesheet" must be 
> declared.
> [Error] autoidx.xsl:27:50: Element type "xsl:variable" must be declared.
> [Error] autoidx.xsl:28:49: Element type "xsl:variable" must be declared.
> [Error] autoidx.xsl:32:79: Element type "xsl:key" must be declared.
> [Error] autoidx.xsl:36:27: Element type "xsl:key" must be declared.
> [Error] autoidx.xsl:40:55: Element type "xsl:key" must be declared.
> [Error] autoidx.xsl:44:74: Element type "xsl:key" must be declared.
> [Error] autoidx.xsl:48:27: Element type "xsl:key" must be declared.
> [Error] autoidx.xsl:52:56: Element type "xsl:key" must be declared.
> [Error] autoidx.xsl:56:76: Element type "xsl:key" must be declared.
> [Error] autoidx.xsl:60:95: Element type "xsl:key" must be declared.
> [Error] autoidx.xsl:64:90: Element type "xsl:key" must be declared.
> [Error] autoidx.xsl:68:86: Element type "xsl:key" must be declared.
> [Error] autoidx.xsl:70:71: Element type "xsl:key" must be declared.
> [Error] autoidx.xsl:73:37: Element type "xsl:template" must be declared.
>
> followed by many more lines of errors.
>
> What I have done is this:
> 1. Downloaded docbook-xsl-1.72.0
> 2. Downloaded fop-0.93 (which contains Xalan)
> Unzipped them both in a directory C:\dbk. So this directory contains 2 
> subdirectories.
>
>
> My command-line is this (added new-lines for formatting purposes):
> java -cp C:\dbk\fop-0.93\build\fop.jar;
>     C:\dbk\fop-0.93\lib\xalan-2.7.0.jar;
>     C:\dbk\fop-0.93\lib\xml-apis-1.3.02.jar;
>     C:\dbk\fop-0.93\lib\xercesImpl-2.7.1.jar;
>     C:\dbk\docbook-xsl-1.72.0\extensions\xalan27.jar
> org.apache.xalan.xslt.Process
> -in sample.xml
> -out "sample.html"
> -xsl "C:\dbk\docbook-xsl-1.72.0\html\docbook.xsl"
> -param use.extensions 1
>
> I cannot figure out why I am getting these errors. By the way, I am 
> fairly new to Docbook and XSL so it may be something very obvious for 
> more experienced people.
>
> Thanks for your help,
> Mike.
>
>
>
>
>
> ____________________________________________________________________________________
> TV dinner still cooling?
> Check out "Tonight's Picks" on Yahoo! TV.
> http://tv.yahoo.com/
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: docbook-apps-unsubscribe@lists.oasis-open.org
> For additional commands, e-mail: docbook-apps-help@lists.oasis-open.org
>
>
> 



---------------------------------------------------------------------
To unsubscribe, e-mail: docbook-apps-unsubscribe@lists.oasis-open.org
For additional commands, e-mail: docbook-apps-help@lists.oasis-open.org






 
____________________________________________________________________________________
The fish are biting. 
Get more visitors on your site using Yahoo! Search Marketing.
http://searchmarketing.yahoo.com/arp/sponsoredsearch_v2.php


[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index] | [List Home]