[XSL-LIST Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message]

RE: multiple output targets (was use-when attribute?)

Subject: RE: multiple output targets (was use-when attribute?)
From: "Michael Kay" <mike@xxxxxxxxxxxx>
Date: Sun, 19 Dec 2004 23:17:57 -0000
output latex
Can't tell what's wrong without seeing your source document.

If you're running Saxon, the -T trace is always useful to understand which
templates are being applied.

The code

         <xsl:for-each select="$bib:formatted-biblist">
           <xsl:apply-templates mode="output-latex"/>
         </xsl:for-each>

is a long-winded way of doing

<xsl:apply-templates 
    select="$bib:formatted-biblist"
    mode="output-latex"/>

Michael Kay
http://www.saxonica.com/

> -----Original Message-----
> From: Bruce D'Arcus [mailto:bdarcus@xxxxxxxxxxxxx] 
> Sent: 19 December 2004 20:54
> To: xsl-list@xxxxxxxxxxxxxxxxxxxxxx
> Subject: Re:  multiple output targets (was use-when attribute?)
> 
> On Dec 18, 2004, at 12:57 PM, Bruce D'Arcus wrote:
> 
> > How's that??
> 
> Seems not so good.
> 
> I just tried to get this working with another output formats, 
> and it's 
> not seeming to apply the output-latex mode templates like I expect.
> 
> So:
> 
> 1)
> 
> <xsl:call-template name="bib:format-bibliography">
>    <xsl:with-param name="output-format" select="latex" tunnel="yes"/>
> </xsl:call-template>
> 
> 2)
> 
>    <xsl:template name="bib:format-bibliography">
>      <xsl:param name="output-format"/>
>      <xsl:choose>
>        <xsl:when test="$output-format='latex'">
> <!-- $bib:formatted-biblist holds the xhtml output -->
>          <xsl:for-each select="$bib:formatted-biblist">
>            <xsl:apply-templates mode="output-latex"/>
>          </xsl:for-each>
>        </xsl:when>
>        <xsl:otherwise>
>          <xsl:copy-of select="$bib:formatted-biblist"/>
>        </xsl:otherwise>
>      </xsl:choose>
> </xsl:template>
> 
> 3)
> 
>    <xsl:template match="xhtml:p[@class='bibref']" mode="output-latex">
>      <xsl:apply-templates mode="output-latex"/>
>      <xsl:text>
>      </xsl:text>
>    </xsl:template>
> 
>  From what I gather, the output-latex mode is never applied.
> 
> Is there something obvious I'm missing?
> 
> Bruce

Current Thread

PURCHASE STYLUS STUDIO ONLINE TODAY!

Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced!

Buy Stylus Studio Now

Download The World's Best XML IDE!

Accelerate XML development with our award-winning XML IDE - Download a free trial today!

Don't miss another message! Subscribe to this list today.
Email
First Name
Last Name
Company
Subscribe in XML format
RSS 2.0
Atom 0.3
Site Map | Privacy Policy | Terms of Use | Trademarks
Free Stylus Studio XML Training:
W3C Member
Stylus Studio® and DataDirect XQuery ™are products from DataDirect Technologies, is a registered trademark of Progress Software Corporation, in the U.S. and other countries. © 2004-2013 All Rights Reserved.