谢谢!if(document.getElementById("Email").value=="") { alert("请输入您的电子邮件!"); return false; }<asp:TextBox runat="server" ID="Email"></asp:TextBox> string sqlInsert = "insert into UserInfo (Name,Sex,Email,tel,Pwd)"; sqlInsert += "values(@Name,@Sex,@Email,@Tel,@Pwd)";该如何实现呢?
function CheckEmail(email){ var reg = new Regex("(?:[a-z\d]+[_\-\+\.]?)*[a-z\d]+@(?:([a-z\d]+\-?)*[a-z\d]+\.)+([a-z]{2,})+","ig"); return reg.test(email);}