Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我完全是 XPath 的新手(我什至不知道如何将正确的 html 粘贴到这篇文章中;-p)主题,我需要一些帮助。我想检索带引号的文本并将其放入 Google 电子表格中的一个单元格中。现在我只能将此文本检索到单独的单元格中。
http://imm.io/oLYI
string(//tr[class='darkGreen']/td[2])结果是你想要的吗?您的 XML 片段看起来不完整,我不确定您是否只想要第二个单元格的内容,所以如果这符合您的需要,这是一个疯狂的猜测。
string(//tr[class='darkGreen']/td[2])