python3 http请求获取url内容

import urllib.request

def get_page(url):
	res = urllib.request.urlopen(url)
	content = res.read().decode()
	return content

str1 = get_page('https://www.bphc.com.cn/front/noroomstaff/checkHavePlanShow')
print(str1)


评论

发表回复

您的电子邮箱地址不会被公开。 必填项已用 * 标注

此站点使用Akismet来减少垃圾评论。了解我们如何处理您的评论数据