Skip to content Skip to sidebar Skip to footer

Beautifulsoup4: How To Retrieve A List Of The Class Name Of Specific Tag

I get that from beautifulsoup4: ABC DEF

Solution 1:

for s in soup.find_all('td'):
    print ''.join(s['class']).strip(), s.text

Post a Comment for "Beautifulsoup4: How To Retrieve A List Of The Class Name Of Specific Tag"