[Home] [By Thread] [By Date] [Recent Entries]

Subject: RE: Test For Numeric Values?
From: <Jarno.Elovirta@xxxxxxxxx>
Date: Fri, 8 Apr 2005 08:03:45 +0300
Hi,

> Writing a style sheet and wanting to test a node value to see
> whether it is
> numeric or not? (Decides HTML align formatting)
>
> <xsl:if test="?">

Check if it's NaN <http://www.w3.org/TR/xpath#numbers> or not.

  not(string(number(node())) = "NaN")

or

  number(node()) = number(node())

Cheers,

Jarno - VNV Nation: Voice

Current Thread
Site Map | Privacy Policy | Terms of Use | Trademarks
Free Stylus Studio XML Training:
W3C Member