为什么我的XPath查询(刮取HTML表)只在Firebug中工作,而不是在我正在开发的应用程序中工作?
这意味着为每周出现一次或两次类似的(但过于具体的问题)提供一个典型的问答。
<!-- snip --><table id="example"> <tr> <th>Example Cell</th> <th>Another one</th> </tr> <tr> <td>foobar</td> <td>42</td> </tr></table><!-- snip -->
//table[@id="example"]/tbody/tr[2]/td[1]
//table[@id]