This is the mail archive of the
xsl-list@mulberrytech.com
mailing list .
RE: Qualified Attrib Value
- From: "Steven Livingstone" <s dot livingstone at BTInternet dot com>
- To: <xsl-list at lists dot mulberrytech dot com>
- Date: Tue, 20 Aug 2002 12:30:47 +0100
- Subject: RE: [xsl] Qualified Attrib Value
- Reply-to: xsl-list at lists dot mulberrytech dot com
Hmmm.... I'm not a fan of this idea of breaking up qualified values by
using string manipulation... It's an XPath function and doesn't really
take into consideration the fact it is qualified.
If I wanted to get the values qualified in a given namespace (e.g. they
are part of an enumeration of colors defined in a color namespace), then
using these string manipulation functions rather than taking into
consideration the namespace it was qualified in would be pretty
ineffective.
So if colors was mapped to "urn:colors" and an associated Xml Schema
defined an enumeration of possible colors, then I would rather use a
qualified means (rather than string functions) to determine if the value
was part of the appropriate namespace.
<el color="colors:red" />
Steven.
-----Original Message-----
From: owner-xsl-list@lists.mulberrytech.com
[mailto:owner-xsl-list@lists.mulberrytech.com] On Behalf Of
Jarno.Elovirta@nokia.com
Sent: 20 August 2002 12:15
To: xsl-list@lists.mulberrytech.com
Subject: RE: [xsl] Qualified Attrib Value
Hi,
> How do I get the value of the "test" attrib (contains a value
> qualified
> in myprefix associated namespace) within this fragment without the
> prefix? (not using string manipulation, but proper Xpath).
>
> <el test="myprefix:val" />
String manipulation is not part of "proper XPath"? Hmh. Anyhow,
substring-before(el/@test, ':')
Cheers,
Santtu & Jarno
XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list
XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list