我正在尝试选择两个月后的日期。我尝试过的代码是:
driver.findElement(By.id("departuredatetime")).click();
driver.findElement(By.xpath("//*[@id=\"ui-datepicker-div\"]/div[1]/table/tbody/tr[4]/td[1]")).click();
driver.findElement(By.id("returningdatetime")).click();
driver.findElement(By.xpath("//*[@id=\"ui-datepicker-div\"]/div[1]/table/tbody/tr[4]/td[2]")).click();
这是网站代码:
<a class="ui-datepicker-next ui-corner-all" data-handler="next" data-event="click" title="Next">
<span class="ui-icon ui-icon-circle-triangle-e">Next</span>
</a>