For some reason, I cannot write the character "3" in the input element of the page.
This code:
chrome_options = Options()
chrome_options.add_argument('--dns-prefetch-disable')
chrome_options.add_argument('--no-proxy-server')
chromeDriverPath = self.getChromeDriverPath()
os.environ["webdriver.chrome.driver"] = chromeDriverPath
self.driver = webdriver.Chrome(chromeDriverPath, chrome_options=chrome_options)
self.driver.get(self.loginUrl)
login = self.driver.find_element_by_id('login_credit')
login.send_keys("12345")
leads to "1245", which is written to the input of the input ... Can someone help please? I am using python 2.7, last chrome and last chrome recorder
EDIT:
login.send_keys("3")
login.send_keys("\3")
also do not work.
login.send_keys("abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ1234567890!@#$%^&*()")
- the line is missing only "3" ...
what worked
login.send_keys(Keys.NUMPAD3)
as Andersson suggested below, but this is not a solution.
I tried this in the google search box and I experienced the same behavior.
source
share