怎样通过脚本判断两次输入的密码是否一致? 如题,怎样通过脚本判断用户在页面上两次输入的密码是一致的?大家有什么好的想法,不妨讨论下。 解决方案 » 免费领取超大流量手机卡,每月29元包185G流量+100分钟通话, 中国电信官方发货 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"><html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=utf-8" /><title>无标题文档</title><script>function isPsSame(){if (document.myform.ps1.value==document.myform.ps2.value){alert("ok");return true;}else{alert("no same");return false;}}</script></head><body><form name="myform" method="post" action="" onsubmit="return isPsSame();"> <input type="password" name="ps1" /> <input type="password" name="ps2" /> <input type="submit" name="button" id="button" value="提交"/></form></body></html> 有兴趣的讨论下分页数据保存的问题? JDBC2005的mysql驱动字符串 netbeans 如何添加Glassfish服务器 hibernate中有外键的表插入数据报错:not-null property references a null or transient value 关于JSP与数据库的联接 jsp:如何屏蔽跳转后的jsp(如:地址栏,菜单栏等) 一个设计的问题 出200分或者更高求JasperReport输出不固定个数列报表的方法 看见了就进来吧! 折磨死! servlet问题 关于JAVA聊天室的问题?请教各位大大!
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>无标题文档</title><script>
function isPsSame()
{
if (document.myform.ps1.value==document.myform.ps2.value)
{
alert("ok");
return true;
}
else
{
alert("no same");
return false;
}
}
</script>
</head><body>
<form name="myform" method="post" action="" onsubmit="return isPsSame();">
<input type="password" name="ps1" />
<input type="password" name="ps2" />
<input type="submit" name="button" id="button" value="提交"/>
</form>
</body>
</html>