xPath axes weirdness
This is an open discussion with 12 replies, filed under XSLT.
Search
Well, parent::*
is the same as ..
while parent::*/entry
would be the equivalent to ../entry
.
..
goes up a level while ../entry
goes up and then down again. I hope that makes sense. :-)
So the answer is
<xsl:if test="count(parent::/entry) > 2">...
Awesome.
@designermonkey: Have I told you lately that I love your avatar picture?
Why thank you!
Apparently, it looks like a baked potato with cress.
I always like to scale the avatars up, it makes it easier to see what is actually on them. Nice photo!
Scaling is useless. Still looks like a baked potato with cress. :-)
Hah!
No, I really like it!
I always like to scale the avatars up, it makes it easier to see what is actually on them. Nice photo!
Weird, when I scaled it up I got this...
LOL
Alright you lot. You're all in trouble!
LOL
Create an account or sign in to comment.
I've never been able to use axes properly in xPath like the following
while
works fine. Take this example
never works yet using
../
instead works every time. I've noticed this a few times in the past, but thought I'd share and ask...Has anyone else seen this behaviour?