How to click Onclick Javascript form using Selenium?

后端 未结 3 1618
悲&欢浪女
悲&欢浪女 2021-02-15 10:31

This is my source code :

Add a
3条回答
  •  长情又很酷
    2021-02-15 10:58

    CSS selector is faster than XPATH so you can try

    driver.findElement(By.cssSelector("a.add-link")).click();
    

提交回复
热议问题