Working with node-sets in Xpath 1.0
I'm working with CALS tables which has multiple colspec elements with tgroup element as a parent. In xpath 2.0 the following works:
colspec/substring-before( @colwidth , '*' )
In xpath 1.0 it complains: Unexpected token - "substring-before( @colwid"
T开发者_如何学运维here has to be a way to accomplish this. I need to sum the number values before the asterisk so that I can convert the relative column widths to percentages. At this point in the day I can't even think of an inelegant solution.
In xpath 1.0 it complains: Unexpected token - "substring-before( @colwid"
That's because right term of /
step operator can't be a function call in XPath 1.0 (This is a feature of XPath 2.0!).
You have to develop a recursive template.
精彩评论