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

RE: Using attributes with XPath

Subject: RE: Using attributes with XPath
From: "Michael Kay" <mike@xxxxxxxxxxxx>
Date: Thu, 24 Aug 2006 09:53:16 +0100
RE:  Using attributes with XPath
> Mike Ferrando wrote:
> 
> Attributes do not have parents. Elements can have parents, 
> but attributes never have parents, children, etc.

This is incorrect. Attributes do have parents. It's just that they aren't
children of their parent.
> 
> 
> Further, XSLT 1.0 does not allow you to write a predicate for 
> an attribute template/@match 

Again, that's incorrect. You can certainly write match="list/@type". 

> At least I have always gotten errors when I 
> have tried to do it. 

Then you've misinterpreted the error messages.

This sort of "black art" programming ("Don't do X because I tried it once
and it didn't work") really needs to be discouraged. Either get to the root
of the problem and discover precisely why the failure occurred, so you can
tell people precisely what to avoid, or leave it in your private to-do list
for later investigation. Don't spread rumours based on anecdotal evidence
that hasn't been investigated.

Michael Kay
http://www.saxonica.com/

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.