|
[XSL-LIST Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message] RE: XPath: all elements with only non-parent children
> > not(*/@style != */@style)] > > Hi Tobias, Jeni: > > maybe a dumb question but why all the "not"s (and writhing > and fainting in > coils?) > wouldn't ... (*/@style = */@style)] > work the same way? Not the same thing at all! A != A, where A is a node-set, is true if there is some node in A that is unequal to another node in A. So "not(A != A)" is true if all the nodes in A have the same string value (brilliant, Jeni!). While "A = A", of course, is true if any node in A has the same value as some node in A - which will always be true, so long as A is not empty, because every node is equal to itself. (This is actually the first time I have ever seen A != B, where the operands are both multi-node node-sets, used for a serious purpose; perhaps I will have to reconsider my previous assumption that it wasn't worth optimising!). Mike Kay XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list
|
PURCHASE STYLUS STUDIO ONLINE TODAY!Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced! Download The World's Best XML IDE!Accelerate XML development with our award-winning XML IDE - Download a free trial today! Subscribe in XML format
|

Cart








