xsl-list
[Top] [All Lists]

RE: simplify XPath expression

2004-01-21 14:58:17
hi,
i was thinking the following xpath could be simplified as it has 
redundant infos. but somehow i cannot bring this to work:


combilist/item/head[1][not(../date)]
[not(../image) and count(../description)=1]                   
              |
combilist/item/head[2][not(../price)]
[not(../image) and count(../description)=1]


the second line in each member of the above union is the same 
so i think 
it must be possible to combine these. i tried

(
      combilist/item/head[1][not(../date)]
      |
      combilist/item/head[2][not(../price)]
)
[not(../image) and count(../description)=1]

but this does not work...

Can you specify in what way it does not work?
Is there an XPath syntax error?
Or does it give you an unexpected result?
If the latter, what result did you get?

Lars


 XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list



<Prev in Thread] Current Thread [Next in Thread>