很多朋友都在迷茫杰奇在Linux环境下,如何完美实现采集内容。最近在规则之树大佬的博客看到一篇关于94采集管理系统(Python采集器)的介绍,正好最近正好有一台Linux上面放了个小站,于是进入了深入浅出的了解,基础设置会在稍晚的文章介绍,这里我们先介绍规则的CSS编写,开工。
PS:所有采集用到的通用参数,单独放在下一个文章,请查阅https://www.xxside.com/3808.html
PS:视频教程请查阅底部下载(CSS采集和正则采集两个视频教程)
采集源站
我们的教程采集源站是qiuyewx,因为是94采集示范规则,而且比较好写。
基本信息
规则名称:随便写
网站地址:写源站地址
网站编码:查看源代码,查找charset,这里是Utf-8就选择Utf-8
参数类型:这里选择启用,这样会规避源站缓存,通俗讲就是为了采集的时候不会因为缓存更新慢
目标地址:可以填写首页、分类页、更新页、完本页、排行榜…这里我选择更新页
列表页设置
一般这个里面就两个重要的地方,这里只写这两个,详细讲解到官网看视频教程
地址规则:.toplists dl>dt>a:eq(1)|href
标题规则:.toplists dl>dt>a:eq(1)
信息页设置
因为图片太长的原因,这个分类就不发了,直接发设置的文字版
标题: meta[property=’og:title’]|content、meta[property=’og:novel:book_name’]|content、h1
作者: meta[property=’og:novel:author’]|content
分类: meta[property=’og:novel:category’]|content
简介: meta[property=’og:description’]|content、#intro
封面: meta[property=’og:image’]|content
状态: meta[property=’og:novel:status’]|content
目录页设置
这里要说明一下,如果用到dd:nth-child(n+9)应该是默认dl 、dt和dd一样的
地址规则:.list>dl dd a|href
标题规则:.list>dl dd a
内容页设置
这个需要注意的是#content和.content,一般“#”用于div的id,而“.”一般用于class
测试采集规则
这里我们都写完以后,为了检查规则是否正规,一定要多次测试,避免后续出现的很多问题。
过滤规则
因为涉及的需求不同,这里不进行赘述。
采集规则
上面的规则可以直接导入使用,测试完美,导入代码如下:
eyJcdTg5YzRcdTUyMTlJRCI6ICIyMDIwMTIxMDIwNTIyOCIsICJcdTg5YzRcdTUyMTlcdTU0MGRcdTc5ZjAiOiAid3d3LnFpdXlld3guY29tIiwgIlx1N2Y1MVx1N2Fk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NWI5YVx1NGU0OVx1OTZjNlx1NTQwOFx1N2QyMlx1NWYxNSI6ICIiLCAiXHU4MWVhXHU1YjlhXHU0ZTQ5XHU2NzAwXHU1OTI3XHU5ODdhXHU1ZThmIjogMCwgIlx1NGUwYlx1NGUwMFx1N2FlMFx1NjgwN1x1OTg5OFx1ODljNFx1NTIxOSI6ICIiLCAiXHU0ZTBiXHU0ZTAwXHU3YWUwXHU2ODA3XHU5ODk4XHU4OWM0XHU1MjE5XHU3YzdiXHU1NzhiIjogIjAifQ==
总结
好了,这里我们就讲到这里,因为坐着本身有视频教程,我这里只对94采集进行简单的描述,官网(www.so94.xyz)有详细的群号和视频教程,有需要的可以去加群获取一下,这里不做太多的介绍。
最后,本教程只希望大家学习交流,切勿用于盈利目的的任何项目,做知法守法的好公民!!!
有人恶意盗卖淘宝和互站,免费的竟然倒卖到了100多,这里限制到金额下载。
原创文章,作者:Tony,如若转载,请注明出处:https://www.xxside.com/3797.html
思德心语,壹群:799239814