webmagic
webmagic copied to clipboard
xpath 语法解析问题
java code
// 节点存在,查找不到。
String articleHtml = page.getHtml().xpath("//div[@class='article-content']/html()").get();
html code
// .. 省略 html 元素
<div class="article-content">
// .. 省略
</div>
抓取网址:https://toutiao.com/i6530346164955382276