【发布时间】:2019-11-11 12:17:15
【问题描述】:
在理想情况下,我试图弄清楚如何将 html 文档加载到元素列表中,例如:
elements=[['h1', 'This is the first heading.'], ['p', 'Someone made a paragraph. A short one.'], ['table', ['tr', ['td', 'a table cell']]]]
我用 beautifulsoup 玩了一点,但没有办法做到这一点。
这目前可行吗,还是我需要编写解析器。
【问题讨论】: