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

Recursive call trouble

Subject: Recursive call trouble
From: Luke Jones <ljones@xxxxxxxxxxxxxxxxxx>
Date: Wed, 09 Aug 2006 14:06:19 -0500
 Recursive call trouble
Hi,

I'm having trouble making my call work at all.  What I'm trying to do is
break down a large paragraph into single lines of sub-strings.  Here is
what my xsl segment currently looks like:

====XSL=====

<xsl:param name = "start">1</xsl:param>
<xsl:param name = "end">60</xsl:param>
<xsl:param name = "ln">1</xsl:param>

<xsl:template match="fdoc/bl/title" name="intro">
		<xsl:variable name = "num"
select="string-length(fdoc/bl/title/para/text())" />
		
		<title>
			<line number='$ln'>
				<xsl:choose>
					<xsl:when test="$end &gt; $num">
						<xsl:value-of select="substring(floordoc/bill/title/para/text(),
$start)"/>
					</xsl:when>
					<xsl:otherwise>
						<xsl:value-of select="substring(floordoc/bill/title/para/text(),
$start,60)"/>
					</xsl:otherwise>
				</xsl:choose>
			</line>

			<xsl:call-template name="intro">
				<xsl:with-param name = "start" select='$start+60'/>
				<xsl:with-param name = "end" select='$end+60'/>
				<xsl:with-param name = "ln" select= '$ln+1'/>
			</xsl:call-template>
		</title>
	</xsl:template>


Thanks!

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-2011 All Rights Reserved.