I am trying to programmatically click the button running a script on ubuntu server to get access to the website content. I am trying to reach the site with recipies
This is my code:
driver = webdriver.Firefox(executable_path="/home/ubuntu/.linuxbrew/Cellar/geckodriver/0.26.0/bin/geckodriver",options=options)
data = []
# In[34]:
# click GDPR full-width banner
start_time = datetime.now()
driver.get("http://some_web_site.here/")
time.sleep(10)
# gdpr_button = driver.find_element_by_link_text("Continue")
#gdpr_button = driver.find_element_by_xpath('//button[text()="Continue"]')
driver.find_element_by_xpath("//input[@style='order:2' and @onclick='sendAndRedirect()']").click()
# //input[@onclick='sendAndRedirect()']
# <button style="order:2" onclick="sendAndRedirect();">Continue</button>
However, i cannot reach the element and get
selenium.common.exceptions.TimeoutException: Message: connection refused
How can I access 'Continue' button in GDPR form? Appreciate your help