Hello all,

I've a stylesheet:

<xsl:stylesheet
         xmlns:xsl="http://www.w3.org/1999/XSL/Transform";
         xmlns:fo="http://www.w3.org/1999/XSL/Format"; version="1.0"
         xmlns:xalan="http://xml.apache.org/xslt";>

        <xsl:import href="./Ad_Spec_Proof1.xsl"/>
        <xsl:import href="./Ad_Spec_Proof2.xsl"/>
                 
        <xsl:output method="xml" indent="yes" xalan:indent-amount="4"/>
        <xsl:strip-space elements="*"/>
        ....

now there is a choose->when->otherwise construct which decides which
template should be used dependent on the data from the xml-source.

On transformation I get this Error:
javax.xml.transform.TransformerException: xsl:import is not allowed in this 
position in the stylesheet!
        at 
org.apache.xalan.processor.StylesheetHandler.error(StylesheetHandler.java:950)
        at 
org.apache.xalan.processor.StylesheetHandler.getProcessorFor(StylesheetHandler.java:420)
        ...

The spec says: The xsl:import element can only be a child of the xsl:stylesheet 
or the
xsl:transform elements. Further, the xsl:import element must be the first 
element to occur
after the xsl:stylesheet element

I also tried xsl:include with the same success ;(

Any help would be appreciated

-- 
Best regards,
 Torsten                          mailto:[EMAIL PROTECTED]


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

Reply via email to