每天一点点,记录学习
爬取网易榜单云音乐–一首
那三个小点点,找到下载,然后右键,检查,找到User-Agent
这样一首歌就能下载好啦
h = {找到的User-Agent那块}
response = requests.get(url,headers = h)
data = response.content #字节流格式哦
with open ('歌名或者随便取名字喽.mp3','wb') as f:
f.write(data)
每天一点点,记录学习
爬取网易榜单云音乐–一首
那三个小点点,找到下载,然后右键,检查,找到User-Agent
这样一首歌就能下载好啦
h = {找到的User-Agent那块}
response = requests.get(url,headers = h)
data = response.content #字节流格式哦
with open ('歌名或者随便取名字喽.mp3','wb') as f:
f.write(data)