<! DocType html> <html> <head> <meta http-equiv = "content-type" content = "text/html; charset = utf-8"/> <title> 防止重复表单提交 </title> <style> #Refresh {Pantalla: Ninguno; Ancho: 200px; Altura: 20px; Color de fondo: #FF0; } </style> <script> var inprocess = false; Window.Onload = function () {document.forms ["Picker"]. OnsubMit = ValidatesubMit; document.getElementById ("actualizar"). onClick = startver; } función validateSubMit () {// 防止重复的表单提交 if (inProcess) return; inProcess = true; console.log (inProcess); document.getElementById ("SubtButton"). DISCABILED = True; document.getElementById ("actualizar"). style.display = "bloque"; document.getElementById ("Mensaje"). Innerhtml = "<p> 正在 Processing , 稍等 </p>"; devolver falso; } function startver () {inProcess = false; document.getElementById ("SubtButton"). DISCABILED = FALSE; document.getElementById ("Mensaje"). InnerHtml = ""; document.getElementById ("refresh"). style.display = "none"; } < /script> </head> <body> <form id = "picker" método = "post" action = ""> group1: <input type = "radio" name = "group1" valor = "one" /> grupo2: <input type = "radio" name = "group1" valor = "dos" /> grupo3: <input type = "radio" name = "group1" valor = "tres" /> <br /> <br /> input 1 input 1: <ext ": <Text": <Text ": <brey": <text ": <brey". id = "Intext"/> Enumer 2: <input type = "text" id = "intext2"/> input 3: <input type = "text" id = "intext3"/> <input type = "subt" id = "SubtButton" valor = "Enviar formulario"/> </form> <divi = "refrescar"> <p> 单击我 </p> </iv> <iv Id = "Message"> </Divi "</Body </Divi </html>