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

Re: substring function not handling hyphens in variabl

Subject: Re: substring function not handling hyphens in variables correctly
From: Tony Graham <Tony.Graham@xxxxxxxxxxxxxxx>
Date: Thu, 13 Sep 2001 17:43:48 +0100
substring is not a function
Chas Mick wrote at 13 Sep 2001 11:36:46 -0400:
 > I have just upgraded from Xalan 1.0.0 to Xalan
 > 1.3.  The following snippets no longer function
 > correctly:
 > 
 > <xsl:value-of
 > select="concat(substring($user,1,3),substring($user,5,6),substring($user,8,11))"/>

Since you're really only worried about '-' characters, You could just
use:

<xsl:value-of select="translate($user, '-', '')"/>

Regards,


Tony Graham
------------------------------------------------------------------------
XML Technology Center - Dublin        mailto:tony.graham@xxxxxxxxxxxxxxx
Sun Microsystems Ireland Ltd                       Phone: +353 1 8199708
Hamilton House, East Point Business Park, Dublin 3            x(70)19708

 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.