'BeautifulSoup - find table with specified class on Wikipedia page

I am trying to find a table in a Wikipedia page using BeautifulSoup and for some reason I don't get the table. Can anyone tell why I don't get the table?

my code:

import BeautifulSoup
import requests

url='https://en.wikipedia.org/wiki/List_of_National_Historic_Landmarks_in_Louisiana'
r=requests.get(url)
url=r.content
soup = BeautifulSoup(url,'html.parser')

tab=soup.find("table",{"class":"wikitable sortable jquery-tablesorter"})
print tab

prints: None



Solution 1:[1]

You shouldn't use jquery-tablesorter to select against in the response you get from requests because it is dynamically applied after the page loads. If you omit that, you should be good to go.

tab = soup.find("table",{"class":"wikitable sortable"})

Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source
Solution 1 wpercy