xsl-list
[Top] [All Lists]

RE: [xsl] Using attributes with XPath

2006-08-24 09:03:49
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/


--~------------------------------------------------------------------
XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list
To unsubscribe, go to: http://lists.mulberrytech.com/xsl-list/
or e-mail: <mailto:xsl-list-unsubscribe(_at_)lists(_dot_)mulberrytech(_dot_)com>
--~--