I want to extract certain information out of an html document. E.g. it contains a table
(among other tables with other contents) like this:
-
2020-12-10 15:25
>>> from bs4 import BeautifulSoup
>>> soup = BeautifulSoup(unicodestring_containing_the_entire_htlm_doc)
>>> table = soup.find('table', {'class': 'details'})
>>> th = table.find('th', text='Issued on:')
>>> th
Issued on: |
>>> td = th.findNext('td')
>>> td
2013-06-13 |
>>> td.text
u'2013-06-13'