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

URL Encoding

Subject: URL Encoding
From: "Serdar Kilic" <serdar@xxxxxxxxxx>
Date: Wed, 9 May 2001 20:02:15 +1000
url encoding script
Hi All,
  Thanks to all who helped my url encoding problem, even though I had
trouble getting it working :)
Here is a solution that I found, although it relies on the msxsl namespace.

 <msxsl:script language="JScript" implements-prefix="user">
 <![CDATA[
    function urlEncode(strURL)


     return encodeURI(strURL);

    }
    ]]>
 </msxsl:script>

..that's it, and then down below I call it like this:

<xsl:value-of select="user:urlEncode(string(//parentCategory))" />

one weird problem that I had was that I *had* to use the string function, I
thought that (//parentCategory) would have been fine as is, but I was
mistaken.

The script relies on version 5.5 of the Microsoft Script Engine.

Regards,
Serdar


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


Current Thread
  • URL Encoding
    • Serdar Kilic - Wed, 9 May 2001 06:01:19 -0400 (EDT) <=

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.