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

RE: newbie question: how do i capitalize text?

Subject: RE: newbie question: how do i capitalize text?
From: "Duane Nickull" <duane@xxxxxxxxxxxxx>
Date: Fri, 21 Jan 2000 09:10:59 -0800
capitalize text
Title: newbie question: how do i capitalize text?
Joni:
 
Becuase XML is case sensetive,  a transformation of case is semantically equivalent to transforming to a new string.  As far as I know,  there is no XSL functionality to easily convert from one to the other. 
 
Becuase I can see you are wanting an HTML output,  I would presume the end user of your data is using a browser.
Accordingly, I would suggest that your best (and probably the most elegant solution) would be to employ a third party scripting language like _javascript_.   I believe the function is String.toUpperCase()
 
Use the following wrapper for any _javascript_ within an XSL stylesheet: 
 
<xsl:comment>
<![CDATA[  
 
your code here
 
]]>
</xsl:comment>
 
Duane Nickull

[Duane Nickull]  -----Original Message-----
From: owner-xsl-list@xxxxxxxxxxxxxxxx [mailto:owner-xsl-list@xxxxxxxxxxxxxxxx]On Behalf Of Joni Fazo
Sent: Thursday, January 20, 2000 5:37 PM
To: 'XSL-List@xxxxxxxxxxxxxxxx'
Subject: newbie question: how do i capitalize text?

Hello,

Is it possible to capitalize some text that my xsl file selects from xml?

If I have some XML like:
<DOCUMENT>
        <GREETING>Hello World!</GREETING>
</DOCUMENT>


and some XSL like:
<html>
<b><xsl:value-of select="GREETING"/></b>
</html>

Is there any way to capitalize the result of <xsl:value-of select="GREETING"/> so I get "HELLO WORLD!" instead of "Hello World!"?

Thanks,
Joni

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.