Javascript 需要帮助单击ghost inspector中的按钮吗

Javascript 需要帮助单击ghost inspector中的按钮吗,javascript,click,ghost-inspector,Javascript,Click,Ghost Inspector,我尝试了以下所有选项: 1) 最大化屏幕并单击按钮-不起作用 top.window.moveTo(0,0); if (document.all) { top.window.resizeTo(screen.availWidth,screen.availHeight); } else if (document.layers||document.getElementById) { if (top.window.outerHeight<screen.availHeight||top.window.

我尝试了以下所有选项:

1) 最大化屏幕并单击按钮-不起作用

top.window.moveTo(0,0);
if (document.all) {
top.window.resizeTo(screen.availWidth,screen.availHeight);
}
else if (document.layers||document.getElementById) {
if (top.window.outerHeight<screen.availHeight||top.window.outerWidth<screen.availWidth){
top.window.outerHeight = screen.availHeight;
top.window.outerWidth = screen.availWidth;
}
}
top.window.moveTo(0,0);
如果(全部文件){
top.window.resizeTo(screen.availWidth、screen.availHeight);
}
else if(document.layers | | document.getElementById){

if(top.window.outerHeights)你不就是:
document.getElementById('button-id').click();
?我已经有一段时间没有使用ghostinspector了,我使用jQuery来处理dom而不是普通的js。代码如下。我在这里没有id选项。我使用的是driver.findElement(By.xpath(//a[@href=“javascript:”;“和@class=“btn btn outline incred button next”])。最初单击。如果没有,我尝试了其他选项work@Sapna如果您对此仍有疑问,请联系支持部门,我们将帮助您找到解决方案:您是否愿意:
document.getElementById('button-id')。单击();
?我已经有一段时间没有使用ghostinspector了,我使用jQuery来处理dom而不是普通的js。代码如下。我在这里没有id选项。我使用的是driver.findelee(By.xpath(//a[@href=“javascript:;”和@class=“btn btn outline incred button next”]))。最初单击。如果没有,我尝试了其他选项work@Sapna如果您对此仍有疑问,请联系支持部门,我们将帮助您找到解决方案: