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

(newbie) problem with parameters in call-template.

Subject: (newbie) problem with parameters in call-template.
From: Glen Mazza <glenmazza@xxxxxxxxx>
Date: Mon, 16 Aug 2004 15:19:16 -0700 (PDT)
fo block parameters
Hello,

I'm currently using XSLT for FO work, and one of my
templates is not working the way I intended it to.

(To show the problem below, I have truncated the files
as much as possible--so the invalid XSL FO here can be
ignored.)

Here is my XML:

<report/>

Here is my XSL:

<xsl:stylesheet
xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
	xmlns:fo="http://www.w3.org/1999/XSL/Format"
	version="1.0">

<xsl:template match="report">
   <fo:static-content flow-name="xsl-region-before">
     <xsl:call-template
name="get-xsl-region-before-header">
         <xsl:with-param name="second-line-right"> 
             <fo:block>System Codes
<fo:retrieve-marker retrieve-class-name="code" 
                        retrieve-boundary="page"
retrieve-position="first-starting-within-page"/>
             <fo:block>-</fo:block>
             <fo:retrieve-marker 
                 retrieve-class-name="code" 
                 retrieve-boundary="page" 
                
retrieve-position="last-ending-within-page"/>
            </fo:block>
         </xsl:with-param>
      </xsl:call-template>
  </fo:static-content>
</xsl:template>

<xsl:template name="get-xsl-region-before-header">
    <xsl:param name="second-line-right"/> 
        <fo:block>
           <xsl:value-of select="$second-line-right"/>
        </fo:block>
</xsl:template>

</xsl:stylesheet> 


Here is my resultant document after running the
transformation:

<fo:static-content
xmlns:fo="http://www.w3.org/1999/XSL/Format"
flow-name="xsl-region-before">
   <fo:block>System Codes -</fo:block>
</fo:static-content>

But this is what I wanted it to look like:

<fo:static-content
xmlns:fo="http://www.w3.org/1999/XSL/Format"
flow-name="xsl-region-before">
    <fo:block>System Codes <fo:retrieve-marker
retrieve-class-name="code" 
        retrieve-boundary="page"
retrieve-position="first-starting-within-page"/>
        <fo:block>-</fo:block>
      <fo:retrieve-marker retrieve-class-name="code"
retrieve-boundary="page" 
        retrieve-position="last-ending-within-page"/>
    </fo:block>
</fo:static-content>

I.e., just have it display what is between the
with-params of the upper template.  Any idea what I am
doing wrong?

Thanks,
Glen



	
		
__________________________________
Do you Yahoo!?
New and Improved Yahoo! Mail - 100MB free storage!
http://promotions.yahoo.com/new_mail 

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.