上一页 1 ··· 8 9 10 11 12 13 14 15 16 ··· 18 下一页
摘要: 流程框架 1. 抓取单页内容 利用requests请求目标站点,得到单个网页HTML代码,返回结果。 2. 正则表达式分析 根据HTML代码分析得到电影的名称、主演、上映时间、评分、图片链接等信息。 3. 保存至文件 通过文件的形式将结果保存,每一部电影一个结果一行Json字符串。 4. 开启循环及 阅读全文
posted @ 2018-12-05 15:19 cicarius 阅读(290) 评论(0) 推荐(0) 编辑
摘要: Introduction One of the easiest way of increasing the responsiveness of your server and guarding against out of memory errors in applications is to ad 阅读全文
posted @ 2018-12-05 09:37 cicarius 阅读(275) 评论(0) 推荐(0) 编辑
摘要: 自动化测试工具,支持多种浏览器。爬虫中主要用来解决JavaScript渲染的问题。 用法讲解 模拟百度搜索网站过程: 声明浏览器对象 访问页面 查找元素 单个元素 输出结果: 常用的一些方法: find_element_by_name find_element_by_xpath find_eleme 阅读全文
posted @ 2018-12-03 17:17 cicarius 阅读(336) 评论(0) 推荐(0) 编辑
摘要: 显示行号: set nu 去除行号: set nonu 阅读全文
posted @ 2018-12-03 16:50 cicarius 阅读(1079) 评论(0) 推荐(0) 编辑
摘要: 强大又灵活的网页解析库。如果你觉得正则写起来太麻烦,如果你觉得BeautifulSoup语法太难记,如果你熟悉jQuery的语法,那么PyQuery就是你的最佳选择。 安装 pip3 install pyquery 用法讲解 字符串初始化 显示效果如下: URL初始化 直接输入网址,显示效果如下: 阅读全文
posted @ 2018-12-03 13:21 cicarius 阅读(525) 评论(0) 推荐(0) 编辑
摘要: 安装 pip3 install beautifulsoup4 解析库 | 解析器 | 使用方法 | 优势 | 劣势 | | |: :| :| :| | Python标准库 | BeautifulSoup(markup,'html,parser') | Python的内置标准库、执行速度适中、文档容错 阅读全文
posted @ 2018-12-03 08:53 cicarius 阅读(470) 评论(0) 推荐(0) 编辑
摘要: 官方声明地址:http://www.cnblogs.com/cmt/p/markdown_github.html 标题 只要前面加 号即可,一共六级标题 列表 无序列表 无序列表前面加 无序列表前面加 无序列表前面加 有序列表 1. 前面加列号序号1 2. 前面加列号序号2 3. 前面加列号序号3 阅读全文
posted @ 2018-12-02 08:51 cicarius 阅读(247) 评论(0) 推荐(0) 编辑
摘要: 符号 说明 编码 符号 说明 编码 符号 说明 编码 ” 双引号 &quot; × 乘号 &times; ← 向左箭头 &larr; & AND符号 &amp; ÷ 除号 &divide; ↑ 向上箭头 &uarr; <  小于 阅读全文
posted @ 2018-12-02 08:43 cicarius 阅读(2497) 评论(1) 推荐(1) 编辑
摘要: 非Python独有,re模块实现 re.match re.match尝试从字符串的起始位置匹配一个模式,如果不是起始位置匹配成功的话,match()就返回none. re.match(pattern,string,flags=0) 最常规的匹配 41 (0, 41) Hello 123 4567 W 阅读全文
posted @ 2018-12-02 04:26 cicarius 阅读(228) 评论(0) 推荐(0) 编辑
摘要: /etc/apt/sources.list 具体方法参考: http://blog.csdn.net/gmnet/article/details/14471835 http://blog.sina.com.cn/s/blog_6d0d6cff0101ddjb.html http://blog.csd 阅读全文
posted @ 2018-11-29 09:12 cicarius 阅读(255) 评论(0) 推荐(0) 编辑
上一页 1 ··· 8 9 10 11 12 13 14 15 16 ··· 18 下一页