如何使用JavaScript
perl
运行此Mechanize
?
function __doPostBack(eventTarget, eventArgument) {
var theform;
if (window.navigator.appName.toLowerCase().indexOf("microsoft") > -1) {
theform = document.Form1;
}
else {
theform = document.forms["Form1"];
}
theform.__EVENTTARGET.value = eventTarget.split("$").join(":");
theform.__EVENTARGUMENT.value = eventArgument;
theform.submit();
}
答案 0 :(得分:0)
$mech->form_name("Form1");
$mech->field("__EVENTTARGET", $eventTarget);
$mech->field("__EVENTARGUMENT", $eventArgument);
$mech->submit();