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

RE: seperating alphanumeric string in two preferably u

Subject: RE: seperating alphanumeric string in two preferably using fxsl
From: Jarno.Elovirta@xxxxxxxxx
Date: Thu, 21 Mar 2002 11:53:24 +0200
alphanumeric s
Hi,

> I've got elements that will have alphanumeric strings in the 
> format of css
> values, for example 11px or 150%(would one classify that as 
> alphanumeric?)
> or 5em, 5.5in and so forth. normally what I would do is have 
> a parameter
> with a nodeset of values like
> <value>in</value>
> <value>em</value>
> then a variable that gets the value that is contained in my 
> element, then
> get the substring-before the value. Am thinking someone might 
> have either a
> generic template that already does something like this(help me not to
> work!), or can give me a better suggestion for how I should build my
> template(help me to improve myself!), or maybe Dimitre has an 
> idea how this
> could be done using the fxsl library(help me develop my brain!).

I didn't really get your question, but if it was how to get the value and unit of a CCS value, you could try <xsl:value-of select="translate($value, '%acdegHikmnprstxz', '')" /> to get the value and <xsl:value-of select="translate($value, '0123456789.', '')" /> for the unit. That will not parse colour and URI values, but that shouldn't be too difficult to do.

Santtu


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


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.