Use javaScript to click on a link
-
In examples browser,I want to click a link automaticly.
In Qt5.0,
call
evaluateJavaScript("document.getElementById('dd').click();");
on
<a id="dd" href="http://qt-project.org">DD</a>
It works fine.I can open the link in the same tab.But when I run the same code on
<a id="dd" href="http://qt-project.org" target="_black">DD</a>
nothing happened.in Qt 4.0,everything is fine,I can open the link, with or without target="_black"
-
You probably wanted target="_blank"
or you don't have frame with that name "_black"
or due to security restrictions originating frame (e.g. main frame) doesn't have access to the other frame ( "_black")