如何从多个URL python下载所有PDF文件
使用python
,我想从网站
url_asn="https://www.asn.fr/recherche?filter_year[from]={}&filter_year[to]={}&limit=50&search_content_type=&search_text={}&sort_type=date&page={}"
中下载所有PDF文件(以“ INS”开头的名称除外),如果link ['href']不是pdf
,那么打开它并下载PDF文件(如果存在) - 对于每个页面,将其交叉至最后一页。
Using Python
, I'd like to download all pdf files(except names that begin by "INS") from website
url_asn="https://www.asn.fr/recherche?filter_year[from]={}&filter_year[to]={}&limit=50&search_content_type=&search_text={}&sort_type=date&page={}"
if link['href'] is not pdf
, then open it and download pdf files if they exist - for each page, interate to last page.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
可能会起作用吗?
我添加了每行评论。
probably this will work?
I have added comments for every line.