Home:ALL Converter>Page reloads after submitting the 2captcha token

Page reloads after submitting the 2captcha token

Ask Time:2021-09-20T22:10:21         Author:Arfath Yahiya

Json Formatter

I'm trying to signup on twitter using selenium and using 2captcha API to solve the captcha but for some reason when clicking continue the page refreshes and doesn't proceed

        captchaInput = twitter_driver.find_element_by_id('g-recaptcha-response')
        print("Text area set to visible")
        twitter_driver.execute_script("arguments[0].setAttribute('style','display:visible;');", captchaInput)
        time.sleep(5)
        print("Entering captcha token")
        captchaInput.send_keys(captcha_token)
        time.sleep(5)
        button_click = "javascript:document.getElementById('continue_button').click();"
        twitter_driver.execute_script(button_click)

Author:Arfath Yahiya,eproduced under the CC 4.0 BY-SA copyright license with a link to the original source and this disclaimer.
Link to original article:https://stackoverflow.com/questions/69255887/page-reloads-after-submitting-the-2captcha-token
Vadim :

if you write on Python try to do so\nwait.until(EC.element_to_be_clickable((By.CSS_SELECTOR, '#your selector'))).click()\n\nthere very good all written https://selenium-python.readthedocs.io/locating-elements.html#:~:text=content%20%3D%20driver.find_element_by_css_selector(%27p.content%27)\nif at your don`t try describe the error in more detail",
2021-09-20T14:34:52
yy