2012-08-26 36 views
0

什麼可以實現自己的javascript代碼點擊此表單?如何把自動點擊這個表格與JavaScript

<head><script language=JavaScript1.2></script> 
    </head> 
    <body> 
    <form action="http://www.tumblr.com/follow" id="FormType" method="post" style="display:block; float:left;" onsubmit="_gaq.push(['_trackEvent', 'Iframe', 'Follow', 'c-h-o-c-o-l-a-t-a');"> 

          <input type="hidden" name="form_key" value="QT4EOzpHQoAwecU3oWHu0uThVY"> 
          <input type="hidden" name="id" value="c-h-o-c-o-l-a-t-a"> 
          <input type="image" src="http://assets.tumblr.com/images/iframe_follow_alpha.png?1037" style="width:58px; height:20px; border-width:0px; display:block; margin-left:3px; cursor:pointer;" alt="Follow" name="image" id="followbb"> 

         </form> 
</body> 

回答

0

將這個腳本在<head>:(!魔法)

<script type="text/javascript"> 
    function autoClick() { 
    document.forms["FormType"].submit(); 
    } 
window.onload = autoClick; 
</script> 
當文檔完成加載表格將被提交