[XSL-LIST Mailing List Archive Home]
[By Thread]
[By Date]
Re: [xsl] Getting text from string
Subject: Re: [xsl] Getting text from string From: Stan Mikita <markev8@xxxxxxxxx> Date: Thu, 3 Nov 2011 08:26:05 -0400 |
Now I understand. Thanks much On Thu, Nov 3, 2011 at 8:21 AM, Andrew Welch <andrew.j.welch@xxxxxxxxx> wrote: > On 3 November 2011 12:04, Stan Mikita <markev8@xxxxxxxxx> wrote: >> Thanks! >> >> Is it also possible to use the tokenize to retrieve the following? >> >> Input: @path = "dir1/dir2/dir3/dir4/filename" >> >> Output: @path = "dir1/dir2/dir3/dir4" > > Yep, tokenize(@path, '/') will return a sequence of strings, 'dir1', > 'dir'2 etc, everything except the string used to split them. > > You can then rejoin them using string-join($tokens[position() ne last()], '/') > > > -- > Andrew Welch > http://andrewjwelch.com
Current Thread |
---|
|
<- Previous | Index | Next -> |
---|---|---|
Re: [xsl] Getting text from string, Andrew Welch | Thread | Re: [xsl] Getting text from string, Stan Mikita |
Re: [xsl] Getting text from string, Andrew Welch | Date | Re: [xsl] Constructing a sequence: , Andrew Welch |
Month |