XSL-T: Quotation marks in patterns

Please, if I'm just being stupid, would somebody kindly explain what I'm
doing wrong?

I *think* there may be a problem in the current (9th July) XSL-T draft
with respect to quotation marks in patterns. For example, in section
6.4, we read:

> A template rule is specified with the xsl:template element. The match 
> attribute is a Pattern that identifies the source node or nodes to which the 
> rule applies...
> 
> This example creates a block for a chapter element and then processes its 
> immediate children.
> 
>               <xsl:template match="chapter">
>                 <fo:block>
>                   <xsl:apply-templates/>
>                 </fo:block>
>               </xsl:template>

In section 6.2 ('Patterns') we read:

> div[@class="appendix"]//p matches any p element with a div ancestor 
> element that has a class attribute with value appendix 

Now I confess I've struggled with the grammar defined in the document
and am not at all confident that I understand it, but it seems to me
that this implies that:

<xsl:template match="div[@class="appendix"]//p">
  <fo:block>
    <xsl:apply-templates/>
  </fo:block>
</xsl:template>

should be valid. XP, however, can't parse it, and this didn't surprise
me at all, because the use of un-handed delimiters around the syntactic
components would baffle most parsers. I couldn't find (but maybe this is
my stupidity) any way in the standard to escape the inner quotation
marks, and in any case this would not seem to me to be a good solution
because it doesn't scale.

What have I missed? I have an actual practical application for the
construct!

-- 
Simon Brooke, Technical Director, Weft Technology Ltd --
http://www.weft.co.uk/

	the weft is not just what binds the web: it is what makes it a web

Received on Monday, 2 August 1999 11:39:38 UTC