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

xsl:when problem

Subject: xsl:when problem
From: "Roel Dillen" <dillenroel@xxxxxxxxxx>
Date: Sun, 4 Sep 2005 18:36:12 +0200
conditional hyperlink
I want to add a conditional hyperlink to my to a certain element 
<xsl:choose>
       <xsl:when test='tag ="blabla"'>
       	<a href="blabla.htm"><xsl:value-of select="tag" /></a>
       </xsl:when>
	<xsl:otherwise>
		<xsl:value-of select="tag" />
	</xsl:otherwise>
</xsl:choose>

This is part of the xsl document

With in the corresponding xml document

<tag>blabla</tag>

This works if the tag-value pair is exactly the above BUT

if, for readability's sake, I try to write the tag-value pair like this
		<tag>
			blabla
		</tag>
then it doesn't match the test criterium

Is there some kind of solution for this (I was thinking about regular
expressions).

Roel




XSLT Processor VersionVendor: TransformiixVendor URL:
              http://www.mozilla.org/projects/xslt/

-- 
No virus found in this outgoing message.
Checked by AVG Anti-Virus.
Version: 7.0.344 / Virus Database: 267.10.18/89 - Release Date: 2-9-2005

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.