本文主要是介绍【爬虫2019,9月】携程eleven参数解密,希望对大家解决编程问题提供一定的参考价值,需要的开发者们随着小编来一起学习吧!
携程:
url='https://hotels.ctrip.com/Domestic/Tool/AjaxHotelList.aspx'
1,经过多次postman,传入参数:page 为翻页的页数
for page in range(1,2):data={"StartTime":"2019-09-12","DepTime":"2019-09-13","RoomGuestCount":"1,1,0","cityId":"2","cityPY":"shanghai","cityCode":"021","cityLat":"31.2363508011","cityLng":"121.4802384079","page":page,
}
2,页面寻找到可以接口数据(就能爬取所有)
data = json.loads(rep.text)
dta=data['html']
dtaa=etree.HTML(dta)
这篇关于【爬虫2019,9月】携程eleven参数解密的文章就介绍到这儿,希望我们推荐的文章对编程师们有所帮助!