Question: Python3/ BeautifulSoup question I'm using beautifulSoup to acces a div but it is printing an empty braket [ ] I whould like to know what
Python3/ BeautifulSoup question
I'm using beautifulSoup to acces a div but it is printing an empty braket [ ] I whould like to know what im doing wrong.
here is my code:
import bs4
from urllib.request import urlopen as uReq
from bs4 import BeautifulSoup as soup
my_url = 'http://weeklyad.publix.com/Publix/BrowseByPage/Index/?StoreID=2597698&PromotionCode=Publix-181004sab&PromotionViewMode=1#PageNumber=2'
uClient = uReq(my_url)
page_html = uClient.read()
uClient.close()
page_soup = soup(page_html, "html.parser")
mydivs = page_soup.findAll("div", {"class": "mobileIDPContent"})
print(str(mydivs))
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
