xml editor

Supported platforms

Compatible with Windows7 & Mac OS X Snow Leopard

Ready for data server software
[XSL-LIST Mailing List Archive Home] [By Thread] [By Date]

Re: [xsl] String Replacement in XML using XSLT


Subject: Re: [xsl] String Replacement in XML using XSLT
From: Abel Braaksma <abel.online@xxxxxxxxx>
Date: Mon, 25 Sep 2006 20:48:59 +0200

Abel Braaksma wrote:
       <xsl:for-each select="tokenize(., '\[|\]')">
       </xsl:for-each>
For XSLT-1 remember to use the exslt:node-set extension

Sorry, no tokenize() function in XPath 1.0.But you can use the contains() suggestion from Mukul.


Also, my apologies for the ugly <xsl:for-each>, that can be done much neater, and even tokenize() is not the best choice I think, but I just wanted to make the point of making your template more readable with an extra step as a tree in a variable.

-- Abel


Current Thread
Keywords
XML Editor | XML Author | WYSIWYG Editors | Schema Editor | XSD Documentation | XSL/XSLT Editor | XQuery | XML Databases | SVN Client
© 2002-2011 SyncRO Soft Ltd. All rights reserved. | Sitemap | Privacy Policy | This website was created & generated with <oXygen/>®XML Editor