简体   繁体   中英

Naukris login button, not able to click

I was trying to automate resume upload procedure for naukri.com, but unable to click on naukris home button. Its not iframe as well.

website : https://login.naukri.com/nLogin/Login.php

Code used :

driver.findElement(By.xpath(".//[@id='emailTxt']")).sendKeys(userName);
Thread.sleep(2000);
driver.findElement(By.xpath(".//*[@id='pwd1']")).sendKeys(password);
Thread.sleep(2000);
driver.findElement(By.xpath(".//*[@id='sbtLog']")).click();

There are two element with id='sbtLog' , the driver finds the first one and click on it, but you need the second one. Look for an element with this id that also has attribute name='Login'

driver.findElement(By.xpath(".//*[@id='sbtLog' and @name='Login']")).click();

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM