<! Doctype html> <html> <head> <meta http-equiv = "content-type" content = "text/html; charset = utf-8"/> <title> 防止重复表单提交 </title> <yoy> #refresh {display: nenhum; nenhum; Largura: 200px; Altura: 20px; Background-Color: #ff0; } </style> <cript> var inProcess = false; window.onload = function () {document.forms ["picker"]. OnsubMit = validateSubMit; Document.getElementById ("Refresh"). OnClick = StartOver; } função validateSubMit () {// 防止重复的表单提交 if (inProcess) return; inprocess = true; console.log (inprocess); document.getElementById ("submitbutton"). desabilitado = true; document.getElementById ("refresh"). style.display = "bloco"; document.getElementById ("mensagem"). Innerhtml = "<p> 正在 Processamento , 稍等 </p>"; retornar falso; } function startover () {inProcess = false; document.getElementById ("submitbutton"). desabilitado = false; document.getElementById ("mensagem"). innerhtml = ""; document.getElementById ("refresh"). style.display = "nenhum"; } </script> </head> <body> <form id="picker" method="post" action=""> group1:<input type="radio" name="group1" value="one" /> group2:<input type="radio" name="group1" value="two" /> group3:<input type="radio" name="group1" value="three" /><br /><br /> Input 1: <input type = "text" id = "Intext" /> Entrada 2: <input type = "text" id = "intext2" /> entrada 3: <input type = "text" id = "intext3" /> <input type = "submit" ids = "submitbutton" /"send formulh" /> < /form> <dd = "" ". id = "mensagem"> </div> </body> </html>