Nov-01-2019, 11:02 AM
there is no problem to parse this page
import requests from bs4 import BeautifulSoup url = 'https://www.microsoft.com/en-us/download/details.aspx?id=56261' resp = requests.get(url) soup = BeautifulSoup(resp.text, 'html.parser') file_info = soup.find('div', {'class':'fileinfo'}) for p in file_info.find_all('p'): print(p.text)
Output:1.0
SurfaceBook2_Win10_18362_19.101.13994.0.msi
SurfaceBook2_Win10_15063_1802509_3.msi
SurfaceBook2_Win10_16299_1803509_3.msi
SurfaceBook2_Win10_17134_19.101.14240.0.msi
SurfaceBook2_Win10_17763_1805009_0.msi
10/14/2019
976.4 MB
622.1 MB
956.9 MB
985.4 MB
985.4 MB
Now, you need to refine it, because there are plenty of nested divs... I leave this to you
If you can't explain it to a six year old, you don't understand it yourself, Albert Einstein
How to Ask Questions The Smart Way: link and another link
Create MCV example
Debug small programs
How to Ask Questions The Smart Way: link and another link
Create MCV example
Debug small programs