腾讯云
开发者社区
文档
建议反馈
控制台
登录/注册
首页
学习
活动
专区
圈层
工具
MCP广场
文章/答案/技术大牛
搜索
搜索
关闭
发布
文章
问答
(9999+)
视频
沙龙
1
回答
美汤结果缺失
的
部分
python
、
beautifulsoup
这里只是它
的
一部分 <a class="fBlackLink"></a> <span> … </我
的
Python代码如下div = soup.find('td', attrs={'class':
浏览 3
提问于2013-09-04
得票数 9
回答已采纳
1
回答
使用<a>提取
BeautifulSoup
标记
python
、
python-2.7
、
beautifulsoup
、
web-crawler
当我从中提取'a‘标签时,我面临着
问题
。import urllib2 soup =
BeautifulSoup
(response, 'html.parser') links = soup.find_al
浏览 0
提问于2015-12-26
得票数 1
回答已采纳
2
回答
BeautifulSoup
中"findAll“和"
find_all
”
的
区别
python
、
xml-parsing
、
html-parsing
、
beautifulsoup
我想用Python解析一个HTML文件,我使用
的
模块是
BeautifulSoup
。import urllib, urllib2, cookielibsite = "http://share.dmhy.orgteam_id%3A407" r
浏览 5
提问于2012-09-09
得票数 39
回答已采纳
1
回答
漂亮汤: bs4.element.ResultSet对象或列表上
的
find_all
?
python
、
html
、
beautifulsoup
、
html-parsing
嗨,所以我在
beautifulsoup
object上应用了
find_all
,发现了一些东西,它是bs4.element.ResultSet object或list。我想在那里进一步做
find_all
,但在bs4.element.ResultSet object上是不允许
的
。我可以遍历bs4.element.ResultSet object
的
每个元素来执行
find_all
。但是我能不能避免循环,直接把它转换回
beautifulsoup
object呢?B<
浏览 0
提问于2016-03-18
得票数 22
回答已采纳
1
回答
find_all
()函数和
BeautifulSoup
包
的
SoupStrainer有什么区别?
python-3.x
、
beautifulsoup
以下代码用于在屏幕上打印html_doc
的
标签,它是一个包含html代码
的
变量:下面的代码返回相同
的
结果: print(
BeautifulSoup
(html_doc, "
浏览 1
提问于2017-11-10
得票数 1
1
回答
BeautifulSoup
find_all
的
问题
python
、
list
、
beautifulsoup
我需要从站点html中检索一些ids,如果我创建一些变量来存储它们,这并不是一件困难
的
工作,但是我想使用一个列表来使其更容易查找和使用。当使用下面这行代码时,终端返回"TypeError:列表索引必须是整数或切片,而不是字符串“: ids = site.find_all('p', class_="frase fr")['id'] 我
的
意思是这就是
问题
所在,我该如何解决它呢?
浏览 15
提问于2020-12-16
得票数 0
回答已采纳
2
回答
如何在python脚本中导入.py
python
、
beautifulsoup
我试图在python脚本中直接导入
BeautifulSoup
库,但我无法安装它,因为我在语法DS213+中使用它,所以我尝试这样做: soup =
BeautifulSoup
(html) for link in soup.find_all('a'):line 17, in <module> sou
浏览 3
提问于2014-02-24
得票数 0
回答已采纳
1
回答
如何从我
的
函数调用导入库
的
函数?
python
在尝试使用
BeautifulSoup
从某些网页获取信息时,有许多重叠
的
代码,因此我想将其作为一个函数,但我想在bs中调用一个函数,比如
find_all
和select。我该怎么做呢?import requests soup =
BeautifulSoup
(result.text, "lxml&qu
浏览 4
提问于2022-07-01
得票数 0
回答已采纳
1
回答
BeautifulSoup
中文本和字符串
的
区别
python
、
beautifulsoup
当我搜索
BeautifulSoup
中包含特定文本
的
标记时,我使用
find_all
(string='text I want')soup.find_all(string='stackoverflow')soup.find_all(text='stackoverflow') 我查看了
浏览 4
提问于2016-03-26
得票数 1
回答已采纳
1
回答
用
BeautifulSoup
进行Python解析
python
、
parsing
、
beautifulsoup
我正在学习用
BeautifulSoup
库解析,我遇到了显示错误 <html><</p> print
浏览 3
提问于2016-12-10
得票数 0
回答已采纳
1
回答
bs4正确地分析了页面,但是
find_all
没有返回任何内容。
python
、
beautifulsoup
我正试着刮这个网站如果我打印lxml解析
的
结果,我就可以在结果中看到我想要
的
结果。但是,
find_all
不返回任何内容。我已经尝试了以下所有内容(所有这些都返回了一个空列表): 'https://www.automationanywhere.com/resources/custome
浏览 3
提问于2021-01-18
得票数 0
1
回答
我在将HTML表格解析为csv时遇到了
问题
python
、
beautifulsoup
我正在尝试解析来自
的
表并将其转换为csv。我使用了下面的代码import urllib2 try: finally: soup=
BeautifulSoup
,结果是很奇怪
的
。我打算
浏览 0
提问于2015-11-28
得票数 2
2
回答
Python美汤如何在ul中找到李?
python-3.x
、
beautifulsoup
soup.find("ul",attrs={"class":"clearfix"}): print(durum) 我想用
BeautifulSoup
在ul中使用li,所以我写了这个命令,但是我得到了一个错误
的
'NavigableString' object has no attribute '
find_all
'。哪里出了
问题</
浏览 25
提问于2021-01-16
得票数 0
回答已采纳
2
回答
无法从python中
的
html页面提取文本
python
、
beautifulsoup
、
html-parsing
我读到了关于
BeautifulSoup
的
文章,并试图使用它。但我无法提取具有给定类名“company-desc-and-排序容器”
的
文本。我甚至不能从html页面中提取标题。这是我尝试过
的
代码:import requests r = requests.ge
浏览 5
提问于2016-12-20
得票数 1
回答已采纳
3
回答
为什么ResultSet对象没有属性“查找”?
python
、
beautifulsoup
我试图在维基百科头版“维基百科
的
其他领域”部分中删除文本。但是,我遇到了错误ResultSet object has no attribute 'find'。我
的
代码有什么
问题
,我如何让它工作?import requestsurl = 'https://en.wikipedia.org/'soup =
BeautifulSou
浏览 4
提问于2020-07-15
得票数 1
回答已采纳
1
回答
如何在
BeautifulSoup
中捕获此异常
python
、
beautifulsoup
可能重复: for item in soup.find(id="start_dateid").
find_all
('option'):
问题
是当页面没有id="start_dateid“时,会生成一个
浏览 4
提问于2012-12-09
得票数 0
回答已采纳
3
回答
BeautifulSoup
-查找徽标
python
、
python-3.x
、
beautifulsoup
我正在开发一个使用
BeautifulSoup
和Python3来识别网站徽标的自动化程序。第一步,我正在寻找图像名称中有“徽标”一词
的
图像。它实际上工作得很好。但是,我想将其扩展到可能包含术语image
的
图像,或者包含在带有类/id/属性
的
链接中
的
图像,或者甚至更深地隐藏在包含“logo”类
的
div中
的
链接。22595" width="122" height="72" border="0&qu
浏览 1
提问于2014-11-02
得票数 2
1
回答
BeautifulSoup
IndexError
python
、
beautifulsoup
、
scraper
我试着从这张表格
的
“工业”行中刮出文字: <th style="padding-right: 0.5em;" scope="row">Industry</th> </
浏览 3
提问于2015-06-26
得票数 0
2
回答
从维基百科抓取表格: AttributeError:'NoneType‘对象没有'
find_all
’属性
datatable
、
screen-scraping
、
wikipedia
我在试着得到每个国家在上次奥运会上获得
的
奖牌数
的
表。我试着使用
find_all
import requestswebsite_text = requests.get('https://en.wikipedia.org/wiki/2016_Summer_Olympics_medal_table').text soup =
BeautifulSoup
(websi
浏览 0
提问于2019-08-18
得票数 0
1
回答
使用bs4与python一起解析文件,如何从锚标记中获取文本?
python
、
html
、
beautifulsoup
TITLE><a href="facebook.com">Face book</a></HTML>from bs4 import
Beaut
浏览 1
提问于2022-06-14
得票数 -3
回答已采纳
点击加载更多
热门
标签
更多标签
云服务器
ICP备案
对象存储
云点播
即时通信 IM
活动推荐
运营活动
广告
关闭
领券