1.创建一个爬虫项目

用crawlspider方法爬取东莞阳光网

2.创建一个爬虫文件

用crawlspider方法爬取东莞阳光网

3.打开items,保存需要的信息

用crawlspider方法爬取东莞阳光网

4.编写爬虫文件

用crawlspider方法爬取东莞阳光网

5.编写管道文件

用crawlspider方法爬取东莞阳光网

6.打开settings,设置头部信息

用crawlspider方法爬取东莞阳光网

设置管道信息

用crawlspider方法爬取东莞阳光网

当某些网址代理进不去需要设置

用crawlspider方法爬取东莞阳光网

7.scrapy crawl dongguan

相关文章: