首页 > 技术文章 > 爬虫headers参数

LoveOpenSourceBoy 2020-10-25 10:14 原文

个人博客,欢迎来撩 fangzengye.com



爬虫headers参数要全


url = ''
headers = {
    'User-Agent': 'Mozilla/5.0 (Windows NT 6.1; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/53.0.2785.143 Safari/537.36',
    'Connection': 'keep-alive',
    'accept': 'text/html,application/xhtml+xml,application/xml;q=0.9,image/webp,*/*;q=0.8',
    'Cookie': cookies,
    'referer':''
}

推荐阅读