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] Re: page-specific footer for chunked output


Well, you could either create templates for handling subtitle and date for
footer, perhaps
using a mode:

<xsl:template match="subtitle" mode="footer">

and the use <xsl:apply-templates select="/book/bookinfo/subtitle"
mode="footer"/>

or you could just select the content of the subtitle:

<xsl:apply-templates select="/book/bookinfo/subtitle/node()"/>

Bob Stayton
Sagehill Enterprises
DocBook Consulting
bobs@sagehill.net


----- Original Message ----- 
From: "Sam Steingold" <sds@gnu.org>
To: <docbook-apps@lists.oasis-open.org>
Sent: Friday, February 04, 2005 6:31 AM
Subject: [docbook-apps] Re: page-specific footer for chunked output


> > * Bob Stayton <obof@fntruvyy.arg> [2005-02-03 23:15:49 -0800]:
> >
> >> also, this strips out all the formating I have in the subtitle.
> >> e.g., "<subtitle>foo <emphasis>bar</emphasis> baz</subtitle>"
> >> is printed by
> >>
> >>  <xsl:if test="//bookinfo"><div class="bookinfo">
> >>    <hr width="100%"/><table width="100%">
> >>     <th><td align="left"><xsl:value-of
select="//bookinfo/subtitle"/></td>
> >>      <td align="right"><xsl:value-of
select="//bookinfo/date"/></td></th>
> >>  </table></div></xsl:if>
> >>
> >> as "<td>foo bar baz</td>" and not "<td>foo <em>bar</em> baz</td>"
> >> why?
> >
> > That's because <xsl:value-of> will return the string value of a node,
which
> > means just the text.  You want to apply-templates instead, so the
<emphasis>
> > is processed by its template too. Just replace:
> > <xsl:value-of select="/book/bookinfo/subtitle"/>
> >
> > <xsl:apply-templates select="/book/bookinfo/subtitle"/>
>
> oops:
>
> No template matches subtitle in bookinfo.
> No template matches date in bookinfo.
>
>
> -- 
> Sam Steingold (http://www.podval.org/~sds) running w2k
> <http://www.camera.org> <http://www.iris.org.il> <http://www.memri.org/>
> <http://www.mideasttruth.com/> <http://www.honestreporting.com>
> ((lambda (x) `(,x ',x)) '(lambda (x) `(,x ',x)))
>
>
>




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