抓取上面对应链接的网页的文章的内容

  

  ele = element.attr("onclick")
self.driver.execute_script(ele)
sub_selenium = self.driver.execute_script("return document.documentElement.outerHTML")
sub_doc = pq(sub_selenium)
subE = sub_doc("div[id='SetContent']").find("p")
for se in subE.items():
print(se.text())

[Python爬虫] :Selenium +phantomjs 利用 pyquery抓取脚本链接对应的内容的更多相关文章

  1. [Python爬虫] 之三十:Selenium +phantomjs 利用 pyquery抓取栏目

    一.介绍 本例子用Selenium +phantomjs爬取栏目(http://tv.cctv.com/lm/)的信息 二.网站信息 三.数据抓取 首先抓取所有要抓取网页链接,共39页,保存到数据库里 ...

  2. [Python爬虫] 之二十八:Selenium +phantomjs 利用 pyquery抓取网站排名信息

    一.介绍 本例子用Selenium +phantomjs爬取中文网站总排名(http://top.chinaz.com/all/index.html,http://top.chinaz.com/han ...

  3. [Python爬虫] 之十六:Selenium +phantomjs 利用 pyquery抓取一点咨询数据

    本篇主要是利用 pyquery来定位抓取数据,而不用xpath,通过和xpath比较,pyquery效率要高. 主要代码: # coding=utf-8 import os import re fro ...

  4. [Python爬虫] 之二十五:Selenium +phantomjs 利用 pyquery抓取今日头条网数据

    一.介绍 本例子用Selenium +phantomjs爬取今日头条(http://www.toutiao.com/search/?keyword=电视)的资讯信息,输入给定关键字抓取资讯信息. 给定 ...

  5. [Python爬虫] 之二十二:Selenium +phantomjs 利用 pyquery抓取界面网站数据

    一.介绍 本例子用Selenium +phantomjs爬取界面(https://a.jiemian.com/index.php?m=search&a=index&type=news& ...

  6. [Python爬虫] 之二十一:Selenium +phantomjs 利用 pyquery抓取36氪网站数据

    一.介绍 本例子用Selenium +phantomjs爬取36氪网站(http://36kr.com/search/articles/电视?page=1)的资讯信息,输入给定关键字抓取资讯信息. 给 ...

  7. [Python爬虫] 之三十一:Selenium +phantomjs 利用 pyquery抓取消费主张信息

    一.介绍 本例子用Selenium +phantomjs爬取央视栏目(http://search.cctv.com/search.php?qtext=消费主张&type=video)的信息(标 ...

  8. [Python爬虫] 之二十九:Selenium +phantomjs 利用 pyquery抓取节目信息信息

    一.介绍 本例子用Selenium +phantomjs爬取节目(http://tv.cctv.com/epg/index.shtml?date=2018-03-25)的信息 二.网站信息 三.数据抓 ...

  9. [Python爬虫] 之十七:Selenium +phantomjs 利用 pyquery抓取梅花网数据

    一.介绍 本例子用Selenium +phantomjs爬取梅花网(http://www.meihua.info/a/list/today)的资讯信息,输入给定关键字抓取资讯信息. 给定关键字:数字: ...

随机推荐

  1. https建立通讯过程及运行机制 [转]

    ssl与tls: SSL:(Secure Socket Layer,安全套接字层),为Netscape所研发,用以保障在Internet上数据传输之安全,利用数据加密(Encryption)技术,可确 ...

  2. springMvc Velocity tool 源码分析

    在公司使用pandoraboot配置了velocity tool,一直不明白官方支持的init方法没有调用,而且不支持velocity tool 1.x版本的定义(1.x和2.x的定义见下面),而另一 ...

  3. Understanding the STM32F0's GPIO

    Understanding the STM32F0's GPIO This is the first part of the GPIO tutorial for the STM32F0Discover ...

  4. 微信emoji表情编码 、MySQL 存储 emoji 表情符号字符集

    相关资料 微信emoji表情编码 微信用户名显示「emoji表情」 PHP处理微信中带Emoji表情的消息发送和接收(Unicode字符转码编码) MySQL 存储emoji表情 MySQL 存储 e ...

  5. ThinkPHP 模型方法 setInc() 和 setDec() 使用详解

    对于数字字段的加减,可以直接使用 setInc() 与 setDec() 方法 ThinkPHP 内置了对统计数据(数字字段)的更新方法: setInc():将数字字段值增加 setDec():将数字 ...

  6. Linux Shell脚本入门--wc命令

    wc 统计文件里面有多少单词,多少行,多少字符. wc语法 [root@www ~]# wc [-lwm] 选项与参数: -l :仅列出行: -w :仅列出多少字(英文单字): -m :多少字符: 默 ...

  7. flashsim配置2015最新版本

    http://blog.csdn.net/Eidosper/article/details/46458469 http://www.doc88.com/p-7314277317013.html htt ...

  8. javascript: break跳出多重循环以及退出each循环

    先来看一个小例子: <html> <body> <script type="text/javascript"> for(j=0;j<2;j ...

  9. Windows Phone本地数据库(SQLCE):13、更新数据(翻译)

    这是“windows phone mango本地数据库(sqlce)”系列短片文章的第十三篇. 为了让你开始在Windows Phone Mango中使用数据库,这一系列短片文章将覆盖所有你需要知道的 ...

  10. UITabBar 详解

    1.push时,将tabar隐藏,方法1,在push之前,加入如下代码: -(IBAction)btnOnClicked:(id)sender { SQVideoListViewController ...