赞
踩
python 知识星球文件下载
#!/usr/bin/python3
# -*- coding: UTF-8 -*-
import requests
import json
from urllib.parse import quote
import os
from pyquery import PyQuery as pq
import datetime
headers = {
'Authorization': '37923FBC-C87D-454C-902D-A81DB0834605',
'x-request-id': "73e67a6f-cf88-4c10-26da-a30441464ed5",
'accept': "application/json, text/plain, */*",
'host': "api.zsxq.com",
'connection': "keep-alive",
'referer': "https://wx.zsxq.com/dweb/",
'user-agent': "Mozilla/5.0 (Windows NT 6.1; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/69.0.3497.100 Safari/537.36",
}
def readtopicurl(filename):
with open(filename, 'r') as f:
url = f.read()
Copyright © 2003-2013 www.wpsshop.cn 版权所有,并保留所有权利。