JApostoles
11-03-2004, 06:59 AM
Given an XML file like this:
<items>
<item>
<text>Some Text</text>
<children>
<child id="1">more text</child>
<child id="2">more text</child>
</children>
</item>
</items>
If I pass a string contaning a datapath to an object, and then use that string as the datapath for the view containing the object, it seems I cannot access the children two-deep.
Example:
If I pass "myData:/items/item" as the datapath string, and then use that in the view, "$path{'text/text()'}" will return "Some Text", which is correct, but if I do $path{'children/child[@id=\\'1\\']/text()'} it doesn't return anything.
Any ideas?
<items>
<item>
<text>Some Text</text>
<children>
<child id="1">more text</child>
<child id="2">more text</child>
</children>
</item>
</items>
If I pass a string contaning a datapath to an object, and then use that string as the datapath for the view containing the object, it seems I cannot access the children two-deep.
Example:
If I pass "myData:/items/item" as the datapath string, and then use that in the view, "$path{'text/text()'}" will return "Some Text", which is correct, but if I do $path{'children/child[@id=\\'1\\']/text()'} it doesn't return anything.
Any ideas?