摘要: requests Python标准库中提供了:urllib、urllib2、httplib等模块以供Http请求,但是,它的 API 太渣了。它是为另一个时代、另一个互联网所创建的。它需要巨量的工作,甚至包括各种方法覆盖,来完成最简单的任务。 Requests 是使用 Apache2 License 阅读全文
posted @ 2018-07-09 20:25 rjm123456 阅读(151) 评论(0) 推荐(0) 编辑
摘要: from django.conf.urls import url from django.contrib import admin from app01 import views urlpatterns = [ url(r'^admin/', admin.site.urls), url(r'^index/',views.index), url(r'^get_json',v... 阅读全文
posted @ 2018-07-09 18:54 rjm123456 阅读(108) 评论(0) 推荐(0) 编辑
摘要: 阅读全文
posted @ 2018-07-09 17:47 rjm123456 阅读(1614) 评论(0) 推荐(0) 编辑
该文被密码保护。 阅读全文
posted @ 2018-07-09 15:45 rjm123456 阅读(1) 评论(0) 推荐(0) 编辑
摘要: import requests from bs4 import BeautifulSoup response = requests.get('https://www.autohome.com.cn/news/') response.encoding = 'gbk' soup = BeautifulSoup(response.text,"html.parser") div =soup.find(n... 阅读全文
posted @ 2018-07-09 13:20 rjm123456 阅读(348) 评论(0) 推荐(0) 编辑