Subject:xsl:import Author:P S Date:05 Dec 2005 03:16 PM
hi
I am trying to imprt another xsl file but in stylus studio its not working. If anyone can tell me what i am doing wrong. I placed both files under same dir and using the syntax.
<xsl:import href="test.xsl"/>
test.xsl is another regular xsl file with output method tobe html.
Subject:xsl:import Author:Minollo I. Date:05 Dec 2005 03:38 PM
The Stylus Studio internal XSLT processor won't merge multiple <xsl:output> directives part of the main, included and imported stylesheets. That's a limitation of the built-in processor.
You can instruct Stylus Studio to use Saxon 6.5, 8.6 or other supported XSLT processors to properly test those scenarios.
Subject:xsl:import Author:P S Date:05 Dec 2005 05:32 PM
hi
I tried using saxon parser but still it doesn't work? I want to include another xsl file at certain location in the other xsl file. If i try to include the xsl:import in the main template it throws an java runtime error - element must only be used at top level of stylesheet .
How do i use xsl:include or xsl:import. I want to build an include file which will be used by 5 other xsl files.
Subject:xsl:import Author:Minollo I. Date:05 Dec 2005 06:24 PM
<xsl:import> and <xsl:include> statements must be direct children of <xsl:stylesheet>, and <xsl:import> must occur before any other <xsl:stylesheet> sub-element.
Subject:xsl:import Author:Minollo I. Date:06 Dec 2005 11:08 AM
Well, judging from what you posted, the included stylesheet doesn't look like a valid stylesheet. The <form> element should be part of some template; it can't be child of the <xsl:stylesheet> element.
As the link attached in my earlier post explains, combining multiple stylesheets gives you the possibility to access matched or named templates defined in included/imported stylesheets from your main stylesheet. That doesn't change or relax any of the XSLT grammar rules for the included or imported stylesheets.
Subject:xsl:import Author:Minollo I. Date:06 Dec 2005 11:37 AM
Without a definition of what "it doesn't work" means, without a stated goal for what you are trying to achieve, and without a reasonably complete example of the XSLT and XML documents you are using, there isn't really anything we can do to help you.
We do require more information if you want more help.