0
https://jsfiddle.net/z1ctm0hd/的Javascript:延遲提交不正確
的jsfiddle產生錯誤的奇怪的名單(PIC http://i.share.pho.to/7e8051a3_l.png)的工作,但是,自動提交正在我的網頁上,但沒有請求的延遲。任何人都可以獲得幫助。
<form id='formBlokUziv' action='' method='post'>
<div class='onoffswitch'>
<input type='checkbox' name='onoffswitch1' value='1' onchange='setTimeout(document.getElementById("formBlokUziv").submit(), 5000);' class='onoffswitch-checkbox' id='myonoffswitch1' >
<label class='onoffswitch-label' for='myonoffswitch1'>
<span class='onoffswitch-inner'></span>
<span class='onoffswitch-switch'></span>
</label>
</div>
<div class='onoffswitch'>
<input type='checkbox' name='onoffswitch2' value='2' onchange='setTimeout(document.getElementById("formBlokUziv").submit(), 5000);' class='onoffswitch-checkbox' id='myonoffswitch2' >
<label class='onoffswitch-label' for='myonoffswitch2'>
<span class='onoffswitch-inner'></span>
<span class='onoffswitch-switch'></span>
</label>
</div>
<div class='onoffswitch'>
<input type='checkbox' name='onoffswitch3' value='3' onchange='setTimeout(document.getElementById("formBlokUziv").submit(), 5000);' class='onoffswitch-checkbox' id='myonoffswitch3' >
<label class='onoffswitch-label' for='myonoffswitch3'>
<span class='onoffswitch-inner'></span>
<span class='onoffswitch-switch'></span>
</label>
</div>
</form>
Thx非常多,問題解決了。 –