docbook-apps

  • 1.  Book title in page footer

    Posted 12-01-2010 15:08
    Hello,

    I have a book title like this "AA<superscript>2</superscript>BB".
    I have my own footer where this book title should appear at center. I have
    the following xsl-code:

    <xsl:when test="($sequence = 'odd' or $sequence = 'even') and $position =
    'center'">
    <xsl:value-of select="ancestor-or-self::book/title">
    </xsl:when>

    Works also fine but the superscript is removed. I think the reason is the
    "ancestor-or-self".
    Please give me a hint how can I insert the book title in the footer with
    the footer.

    Thanks in advance
    Steffen


    Mit freundlichen Grüßen / Kind regards

    Steffen Köhler

    __________________________________________________
    GÖPEL electronic GmbH
    Göschwitzer Straße 58/60
    07745 Jena / Germany

    Tel.: +49-3641-6896-661
    Fax: +49-3641-6896-944
    E-Mail: s.koehler@goepel.com
    http://www.goepel.com


    Sitz der Gesellschaft: GÖPEL electronic GmbH, Göschwitzer Straße 58/60, D-07745 Jena
    Geschäftsführer: Holger Göpel, Manfred Schneider, Thomas Wenzel
    Registergericht: Amtsgericht Jena HR B 201550


  • 2.  Re: [docbook-apps] Book title in page footer

    Posted 12-01-2010 15:40
    Steffen Köhler


  • 3.  Re: Re: [docbook-apps] Book title in page footer

    Posted 12-02-2010 07:56
    Hi,

    I understand, there is no value with the book title: Here is the code that
    work perfectly:

    <xsl:template match="book/title" mode="footer">
    <xsl:apply-templates />
    </xsl:template>
    ...
    <xsl:when test="($sequence = 'odd' or $sequence = 'even') and
    $position = 'center'">
    <xsl:apply-templates select="ancestor-or-self::book/title"
    mode="footer" />
    </xsl:when>

    Thanks
    Steffen



    Von: Markus Hoenicka <markus.hoenicka@mhoenicka.de>
    An: docbook-apps@lists.oasis-open.org
    Datum: 01.12.2010 17:02
    Betreff: Re: [docbook-apps] Book title in page footer



    Steffen Köhler


  • 4.  Re: [docbook-apps] Book title in page footer

    Posted 12-01-2010 16:57
    Steffen Köhler wrote:

    > <xsl:when test="($sequence = 'odd' or $sequence = 'even') and $position =
    > 'center'">
    > <xsl:value-of select="ancestor-or-self::book/title">
    > </xsl:when>
    >
    > Works also fine but the superscript is removed. I think the reason is the
    > "ancestor-or-self".
    > Please give me a hint how can I insert the book title in the footer with
    > the footer.

    You need to use <xsl:apply-templates/> instead of <xsl:value-of/> as
    <xsl:value-of/> always returns string value of expression -- any nested
    markup is ignored.

    Jirka

    --
    ------------------------------------------------------------------
    Jirka Kosek e-mail: jirka@kosek.cz http://xmlguru.cz
    ------------------------------------------------------------------
    Professional XML consulting and training services
    DocBook customization, custom XSLT/XSL-FO document processing
    ------------------------------------------------------------------
    OASIS DocBook TC member, W3C Invited Expert, ISO JTC1/SC34 member
    ------------------------------------------------------------------