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

RE: Line Numbering

Subject: RE: Line Numbering
From: "Spychalski, Frank" <frank.spychalski@xxxxxxx>
Date: Mon, 14 Aug 2000 22:13:56 +0200
textarea line numbering
->-----Original Message-----
->From: Darrin Bishop [mailto:dbishop@xxxxxxxxxxxxxxxxx]
->Subject: Line Numbering

Hi,

->I know that xml is not about formatting, but I need  to 
->transform some xml
->to html that will allow me to put sixty charecters on a line 
->and then break.
->I have not seen any discussion on this nor is there anything 
->in the archives
->that I could find.  Is this not possible with xslt?  I have XSLT
->Programmer's Reference but can not seem to get going in the 
->right direction.

yes, it is possible. Use recursion:

<xsl:template name="out">
  <xsl:param name="text"/>

  ...
  <xsl:value-of select="substring ($text, 1,60)"/>
  ...

  <xsl:if test="substring($text,61) != ''">
    <xsl:call-template name="out">
      <xsl:with-param name="text">
        <xsl:value-of select="substring($text,61)"/>
      </xsl:with-param>
    </xsl:call-template>
  </xsl:if>
</xsl:template>

I didn't test it, but it should work :-)

bye
Frank
-
Frank Spychalski
Research Engineer
SAP Labs, Palo Alto           frank.spychalski@xxxxxxx 


 XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list


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.