<script type="text/javascript" language="javascript">
function jiancha()
{
 if (document.form_body.uname.value=='')
 {
alert("Please enter your name!");
document.form_body.uname.focus();
return false;
 }
}
</script><form action="" id="form_body"  onsubmit="jiancha()" method="post" runat="server"></form>点提交后能弹出错误信息,可点确定后还是提交了!