New Web scrap Proj

This commit is contained in:
Stephen Deaton 2024-06-19 12:35:53 -04:00
commit 1ed36563e3
2 changed files with 18 additions and 0 deletions

View File

@ -0,0 +1,12 @@
import requests
from bs4 import BeautifulSoup
def getdata(url):
r = requests.get(url)
return r.text
htmldata = getdata("https://cs.finescale.com/fsm/m/online/1581353.aspx")
soup = BeautifulSoup(htmldata, 'html.parser')
for item in soup.find_all('img'):
print(item['src'])

View File

@ -0,0 +1,6 @@
import requests
URL = "https://cs.finescale.com/fsm/m/online/1581353.aspx"
page = requests.get(URL)
print(page.text)