0
이 내가 검색하기 위해 노력하고있어 일부 XML이 : 기본적으로속성을 사용하여 복잡한 XPath를 검색합니까?
<debts>
<section id="24" description="YYYYY">
<section id="28" description="xxx">
<section id="31" description="xxx">
<account accountNumber="2312323" creditorId="1" amount="1200" proposedAmount="1000" percentage="11" owner="2">
<foo/>
</account>
</section>
<section id="32" description="xxx"/>
<section id="33" description="xxx"/>
</section>
<section id="29" description="xxx">
<section id="34" description="xxx"/>
</section>
<section id="30" description="xxx">
<section id="37" description="xxx"/>
<section id="38" description="xxx"/>
<section id="39" description="xxx"/>
</section>
</section>
</debts>
를, 내가 뭘하려고 오전, 매우 가능성이 아니라 어떤 (섹션 YYYYY 아래에 앉아 계정의 모든 노드를 찾을 수있다 해당 레벨의 노드 만). 나는 (특히 내가 레일에 Hpricot을 사용하고 있습니다) XPath를 사용하여이 작업을 수행 할 수있는 방법
+1 - 완전성을 위해 : 'YYYYY'에 대한 설명이있는 * 모든 * 섹션 노드 내의 모든 계정 노드를 찾습니다. – Tomalak