refactor(baby): Only zebrina

parent 36ce0743
......@@ -3,14 +3,8 @@ from bs4 import BeautifulSoup
def main():
url_zebrina = "https://onlinebabyplants.com/shop/exclusive-alocasia-zebrina-variegated/"
url_poinsettia = "https://onlinebabyplants.com/shop/poinsettia/"
url_dragon = "https://onlinebabyplants.com/shop/alocasia-pink-dragon/"
for url in [url_zebrina,
url_poinsettia,
# url_dragon
]:
url = "https://onlinebabyplants.com/shop/exclusive-alocasia-zebrina-variegated/"
res = requests.get(url)
soup = BeautifulSoup(res.content, "html.parser")
name = soup.find(attrs={"class": "product_title"}).text
......@@ -30,7 +24,7 @@ def sms(msg: str):
if res.ok:
print("Success!")
else:
print(res.reason, res.headers, res.)
print(res.status_code, res.reason, res.headers)
if __name__ == '__main__':
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment