使用 Python 从 HTML 提供 URL
RSS 提要 URL 可用于站点的元数据(如果可用)。有没有办法使用 urllib2 或 HTMLParser 模块提取页面的 feed URL?或者有更好的模块可用吗?
谢谢。
The RSS feed URL is available a site's meta data (if one available). Is there a way to extract the feed URL(S) of a page using urllib2
or HTMLParser
modules? Or is there a better module available?
Thanks.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
我更喜欢 lxml。它有一个非常好的 API,并且它的 XPath 支持使这变得相当简单:
I prefer lxml. It has a very nice API, and it's XPath support makes this fairly simple to accomplish: