Since my post yesterday, i figured some things out, and i wanted to apologize
for my ignorance on somethings.
I am interested in getting the GenTable elements that have Emphasis elements
with the aforementioned properties.
I got partway there, on my own with the following:
//row/entry[Emphasis = 'Address
Offset']/ancestor::row/following-sibling::row/entry[Emphasis = 'Physical
Address']/following-sibling::entry[Emphasis =
'Instance']/ancestor::row/following-sibling::row/entry[Emphasis =
'Description']/ancestor::row/following-sibling::row/entry[Emphasis =
'Type']/ancestor::GenTable[1]
This more closely matches the location of the elements as they are in the
document, but this still doesn't check for @type='bold' or the condition that
at least 4 of these conditions be true.
As i am using this Xpath, initially within Xmetal's javascript interpreter, i
think they only support the Xpath 1.0 style. When i recast this as a standalone
XSLT script, i will rewrite in an XPath 2.0 style.
All the help you've provided has been great, if this can still be put into one
Xpath expression, i welcome the information and help!
Thanks again!
Russ
On Apr 14, 2009, russurquhart1(_at_)verizon(_dot_)net wrote:
Hi,
I have a structure with conditions something like this:
//GenTable/table/tgroup/tbody/row/entry[Emphasis = 'Address Offset'] and
Emphasis[(_at_)type='bold']
//GenTable/table/tgroup/tbody/row/entry[Emphasis = 'Physical Address'] and
Emphasis[(_at_)type='bold']
//GenTable/table/tgroup/tbody/row/entry[Emphasis = 'Instance'] and
Emphasis[(_at_)type='bold']
//GenTable/table/tgroup/tbody/row/entry[Emphasis = 'Description'] and
Emphasis[(_at_)type='bold']
//GenTable/table/tgroup/tbody/row/entry[Emphasis = 'Type'] and
Emphasis[(_at_)type='bold']
If a GenTable element has four or the five entry elements, that match these
conditions, i want to set GenTable[(_at_)role='Register'] and
GenTable[(_at_)columns='1'].
Can this be squeezed into one hairy Xpath expression.
Sorry still trying to get my head around multiple predicates.
Any help is greatly appreciated!
Thanks,
Russ
--~------------------------------------------------------------------
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>
--~--