用户介绍
结果示例图:
模板:{"_id":"zhihuresearch-user","startUrl":["https://www.zhihu.com/search?q=%E5%BC%80%E5%8F%91%E8%80%85&type=people"],"selectors":[{"id":"outer","type":"SelectorElementScroll","parentSelectors":["_root"],"selector":"div.List-item","multiple":true,"delay":"2000"},
{"id":"user-name","type":"SelectorText","parentSelectors":["outer"],"selector":"span.Highlight","multiple":false,"regex":"","delay":0},{"id":"answers","type":"SelectorText","parentSelectors":
["outer"],"selector":"a.Search-statusLink:nth-of-type(1)","multiple":false,"regex":"","delay":0},{"id":"articles","type":"SelectorText","parentSelectors":
["outer"],"selector":"a:nth-of-type(2)","multiple":false,"regex":"","delay":0},{"id":"followers","type":"SelectorText","parentSelectors":
["outer"],"selector":"a:nth-of-type(3)","multiple":false,"regex":"","delay":0},{"id":"link","type":"SelectorLink","parentSelectors":
["outer"],"selector":"a.UserLink-link","multiple":false,"delay":0},{"id":"intro","type":"SelectorText","parentSelectors":
["outer"],"selector":"div.SearchItem-meta","multiple":false,"regex":"","delay":0}]}
模板套用步骤:
(1)进入知乎搜索结果用户页面,例如:https://www.zhihu.com/search?q=%E5%BC%80%E5%8F%91%E8%80%85&type=people
(2)导入模板
(3)替换 Start URL为要抓取的网页链接
(4)开始抓取