06 2022 档案

摘要:# -*- coding:utf-8 -*- # 1、拿取出页面的源代码,然后提取到子页面的链接地址,href # 2、通过href拿到子页面内容,从子页面找到图片下载地址 img->src # 3、下载图片 import requests from bs4 import BeautifulSoup 阅读全文
posted @ 2022-06-12 20:16 hanyr 阅读(65) 评论(0) 推荐(0) 编辑
摘要:# -*- coding:utf-8 -*- import requests import csv from bs4 import BeautifulSoup url = "http://www.xinfadi.com.cn/priceDetail.html" resp = requests.get 阅读全文
posted @ 2022-06-12 18:58 hanyr 阅读(23) 评论(0) 推荐(0) 编辑
摘要:# -*- coding:utf-8 -*- # 1、拿到页面源代码 # 2、使用bs4解析,拿到数据 import requests from bs4 import BeautifulSoup import csv url = "http://www.xinfadi.com.cn/marketan 阅读全文
posted @ 2022-06-12 18:29 hanyr 阅读(35) 评论(0) 推荐(0) 编辑
摘要:#!/usr/bin/env python # -*- coding: utf-8 -*- import requests import csv import json def test(): f = open("D:/YMM/pythonscript/hyr/file/dmpt个人任务.csv", 阅读全文
posted @ 2022-06-08 14:47 hanyr 阅读(21) 评论(0) 推荐(0) 编辑
该文被密码保护。
posted @ 2022-06-03 16:34 hanyr 阅读(73) 评论(0) 推荐(0) 编辑

点击右上角即可分享
微信分享提示