Reputation: 175
I'm trying to scrape the following page: https://www.heo.co.uk/uk/en/product/FRYU40156
I understand that this is a dynamic website so using the classic Request & Beautiful Soup combo might not work. I'm trying using Selenium and I do get more information by I can't seem to get the following: image of the bit I'm trying to get
I've tried to use By.TAG_NAME and 'h1' but it does not work.
Any ideas of how I can get the header ?
Thanks !
Upvotes: 1
Views: 67
Reputation: 33384
If you go to network tab you will get the following api
https://www.heo.co.uk/api/article
Use the api to get the header value
import requests
payload={
"articleNumber": "FRYU40156",
"language": "en"
}
r=requests.post("https://www.heo.co.uk/api/article",data=payload).json()
print(r['article']['localization']['deName'])
output:
Jujutsu Kaisen 0: The Movie Hikkake PVC Statue Satoru Gojo 10 cm
Upvotes: 1