I am trying to scroll down a webpage "https://www.novitecgroup.com/en/brands/ferrari/roma/" using selenium for python. So far I have tried using following but none seem to work. Please suggest me a better way make it work.
My End goal is to scroll down the webpage and get the browser to automatically click one of those car parts under Suspension and also Aerodynamics.
{NOTE: x in following code is a place holder for a specific part I am trying to scroll to and then click}
using scroll To function
driver.execute_script("window.scrollTo(0, document.body.scrollHeight);")
driver.execute_script("arguments[0].click();", x)
Using arguments.scroll into view function
driver.execute_script("arguments[0].scrollIntoView();", x)
driver.execute_script("arguments[0].click();", x)
Thank you for you help in advance