那位帮我看看这个页面的代码哪有问题?

biti_south 2004-08-20 03:17:07
为什么提交的时候那个Check()怎么都执行不了哪?
<%@LANGUAGE="VBSCRIPT" CODEPAGE="936"%>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<LINK href="Images/common.css" type=text/css rel=stylesheet>
<head>
<script language="javascript">
<!--//
document.frmUser.txtPassWord.focus();
function Check(){
if (document.frmUser.txtPassword.value.length<1) {
window.alert("请输入原始密码!");
return false;
}
if (document.frmUser.txtPswd.value!=src.txtPswd1.value) {
window.alert("两次输入的密码不一致,请重新输入密码!");
return false;
}
return true;
}
//-->
</script>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
<title>无标题文档</title>
</head>

<body>
<form action="SavePassword.asp" method="post" name="frmUser" id="frmUser" onsubmit="return(Check())">
<table width="84%" border="0" align="center">
<tr>
<td height="68" colspan="4"> </td>
</tr>
<tr bgcolor="#E1F0FF">
<td height="24" colspan="4">用户信息修改</td>
</tr>
<tr>
<td width="16%" height="20"> </td>
<td width="13%" height="20">登录帐号</td>
<td width="51%" height="20"><input name="txtID" type="text" id="txtID" value="<%=session("userid")%>" size="30" disabled="true"></td>
<td width="20%" height="20"> </td>
</tr>
<tr>
<td height="20"> </td>
<td height="20">原始密码</td>
<td height="20"><input name="txtPassWord" type="password" id="txtPassWord" size="30"></td>
<td height="20"> </td>
</tr>
<tr>
<td height="20"> </td>
<td height="20">新 密 码</td>
<td height="20" align="left"><input name="txtPswd" type="password" id="txtPswd" size="30"></td>
<td height="20"> </td>
</tr>
<tr>
<td height="20"> </td>
<td height="20">密码确认</td>
<td height="20"><input name="txtPswd1" type="password" id="txtPswd1" size="30"></td>
<td height="20"> </td>
</tr>
<tr>
<td height="20"> </td>
<td height="20">用户名称</td>
<td height="20"><input name="txtName" type="text" id="txtName" size="30"></td>
<td height="20"> </td>
</tr>
<tr>
<td height="20"> </td>
<td height="20">电子邮件</td>
<td height="20"><input name="txtEMail" type="text" id="txtEMail" size="30"></td>
<td height="20"> </td>
</tr>
<tr>
<td> </td>
<td>备注信息</td>
<td><textarea name="txtNotes" cols="32" rows="3" id="txtNotes"></textarea></td>
<td> </td>
</tr>
<tr>
<td height="20" colspan="2" align="center"> </td>
<td height="20" align="left">注:如果某项不用修改,请将该项置空</td>
<td height="20" align="center"> </td>
</tr>
<tr>
<td height="20" colspan="4" align="center" bgcolor="#E1F0FF"><input type="submit" name="Submit" value="提交">  
<input type="button" name="Submit2" value="返回" onclick="window.location.href='main.asp'">
              </td>
</tr>
<tr>
<td colspan="4">  </td>
</tr>
<tr>
<td colspan="4"> </td>
</tr>
</table>
</form>
</body>
</html>
...全文
82 8 打赏 收藏 转发到动态 举报
写回复
用AI写文章
8 条回复
切换为时间正序
请发表友善的回复…
发表回复
  • 打赏
  • 举报
回复
哈哈,我没仔细看呢,js大小写敏感
biti_south 2004-08-20
  • 打赏
  • 举报
回复
怎么把分给了slihome了呢,faint
不过还是要谢谢
biti_south 2004-08-20
  • 打赏
  • 举报
回复
谢谢!
  • 打赏
  • 举报
回复
<form action="SavePassword.asp" method="post" name="frmUser" id="frmUser" onsubmit="return(Check())">
--->
<form action="SavePassword.asp" method="post" name="frmUser" id="frmUser" onsubmit="return Check()">
pizixt 2004-08-20
  • 打赏
  • 举报
回复
if (document.frmUser.txtPassword.value.length<1)
_____________________ txtPassWord

注意大小写
biti_south 2004-08-20
  • 打赏
  • 举报
回复
那块错了 请看下面的那个check()
jzywh 2004-08-20
  • 打赏
  • 举报
回复
if (document.frmUser.txtPswd.value!=src.txtPswd1.value)///这个src哪里来的!
{
window.alert("两次输入的密码不一致,请重新输入密码!");
return false;
}
biti_south 2004-08-20
  • 打赏
  • 举报
回复
上面那个check里面有一句不对,是下面这样的
function Check(){
if (document.frmUser.txtPassword.value.length<1) {
window.alert("请输入原始密码!");
return false;
}
if (document.frmUser.txtPswd.value!=document.frmUser.txtPswd1.value) {
window.alert("两次输入的密码不一致,请重新输入密码!");
return false;
}
return true;
}
提供的源码资源涵盖了Java应用等多个领域,每个领域都包含了丰富的实例和项目。这些源码都是基于各自平台的最新技术和标准编写,确保了在对应环境下能够无缝运行。同时,源码中配备了详细的注释和文档,助用户快速理解代码结构和实现逻辑。 适用人群: 适合毕业设计、课程设计作业。这些源码资源特别适合大学生群体。无论你是计算机相关专业的学生,还是对其他领域编程感兴趣的学生,这些资源都能为你提供宝贵的学习和实践机会。通过学习和运行这些源码,你可以掌握各平台开发的基础知识,提升编程能力和项目实战经验。 使用场景及目标: 在学习阶段,你可以利用这些源码资源进行课程实践、课外项目或毕业设计。通过分析和运行源码,你将深入了解各平台开发的技术细节和最佳实践,逐步培养起自己的项目开发和问题解决能力。此外,在求职或创业过程中,具备跨平台开发能力的大学生将更具竞争力。 其他说明: 为了确保源码资源的可运行性和易用性,特别注意了以下几点:首先,每份源码都提供了详细的运行环境和依赖说明,确保用户能够轻松搭建起开发环境;其次,源码中的注释和文档都非常完善,方便用户快速上手和理解代码;最后,我会定期更新这些源码资源,以适应各平台技术的最新发展和市场需求。 所有源码均经过严格测试,可以直接运行,可以放心下载使用。有任何使用问题欢迎随时与博主沟通,第一时间进行解答!

28,391

社区成员

发帖
与我相关
我的任务
社区描述
ASP即Active Server Pages,是Microsoft公司开发的服务器端脚本环境。
社区管理员
  • ASP
  • 无·法
加入社区
  • 近7日
  • 近30日
  • 至今
社区公告
暂无公告

试试用AI创作助手写篇文章吧