Вопрос

I am new to HTML Unit and XPath. I am not sure of the XPath I need to use to extract the inner table contents inside of a TD of another Table. I have an XML of the following type

<table>
  <tr>
     <td></td>
     <td>
         <table>
           ...
           ... 
         </table> 
     </td> 
   </tr>
  </table>

Appreciate any help here.

Это было полезно?

Решение

So you want to use XPath to get to the inner table. Then you should apply the same logic to get to the outer table.

If you reached the outer table this way:

/path-to-outer-table/table

Then, considering the provided HTML code, you reach the inner table this way:

/path-to-outer-table/table/tr/td/table
Лицензировано под: CC-BY-SA с атрибуция
Не связан с StackOverflow
scroll top