摘要:
# request 请求对象# data 记录请求数据并转换成字符串# form 表单数据# args 查询数据# cookies cookies信息# headers 报头信息# method 请求方式# url 地址# files 上传文件 # from flask import *# app 阅读全文
posted @ 2019-10-06 17:43
斑驳的剪影
阅读(122)
评论(0)
推荐(0)
摘要:
from bs4 import BeautifulSoupimport urllib.requestimport timedef get_request(url): headers = { 'User-Agent': 'Mozilla/5.0 (Windows NT 10.0; Win64; x64 阅读全文
posted @ 2019-10-06 10:54
斑驳的剪影
阅读(227)
评论(0)
推荐(0)
摘要:
import urllib.requestfrom bs4 import BeautifulSoupimport reimport timeimport random# 公用方法 class CommanCalss: def __init__(self): self.header = { 'User 阅读全文
posted @ 2019-10-06 10:52
斑驳的剪影
阅读(163)
评论(0)
推荐(0)
摘要:
import urllib.requestimport urllib.parseimport re,os,time'''拼接url,发送请求,得到响应内容,分析响应内容,保存数据'''def get_request(new_url): headers = { 'User-Agent': 'Mozil 阅读全文
posted @ 2019-10-06 10:47
斑驳的剪影
阅读(900)
评论(0)
推荐(0)

浙公网安备 33010602011771号