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] Chunk transformation error

On Wed, Nov 05, 2003 at 10:06:40PM -0600, Jeffery Biss wrote:
> Hello All,
> I am trying to use the chunk style sheet and get this error message:
> "g:\docbook-xsl-1.62.4\html\chunk.xsl(0,0): The xsl:apply-imports
> instruction may only occur within an xsl:template instruction with a
> match attribute, and may not occur within an xsl:for-each instruction.
> Error occurred during compilation of included or imported stylesheet
> 'chunk-common.xsl'."
> Can anyone offer any advise or information so I can use chunk.xsl? I 
> looked through the files and am not well versed enough to find the problem.
> I am using Wattle software's XMLWriter which uses the MSXML engine 
> (currently 4.0 SP2). Their tech support told me the error message is 
> generated by the MSXML engine.

Very interesting.  It does appear that the stylesheet
is violating the XSLT spec, because it is using
xsl:apply-imports in a template that is called and
not matched (see the XSLT spec section 5.6).
I'd like to know why the other processors didn't flag
this as an error.

You could try copying the template named chunk-element-content
from html/chunk-common.xsl to your customization layer
and modifying the default value for the content parameter:


<xsl:template name="chunk-element-content">
  <xsl:param name="prev"/>
  <xsl:param name="next"/>
  <xsl:param name="nav.context"/>
  <xsl:param name="content">


<xsl:template name="chunk-element-content">
  <xsl:param name="prev"/>
  <xsl:param name="next"/>
  <xsl:param name="nav.context"/>
  <xsl:param name="content"/>

My reading of the stylesheets shows that, with one exception,
this template is always called with the content parameter
set, so making the default null should be no problem.
The one exception is in the separate chunktoc.xsl customization
that is used to manually chunk content.

Bob Stayton                                 400 Encinal Street
Publications Architect                      Santa Cruz, CA  95060
Technical Publications                      voice: (831) 427-7796
The SCO Group                               fax:   (831) 429-1887
                                            email: bobs@sco.com

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