⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 admin_uppwdself.asp

📁 培训学员管理系统
💻 ASP
字号:
<%@LANGUAGE="VBSCRIPT" CODEPAGE="936"%>
<!--#include file="admin_qx.asp" -->
<% isdl %>
<!--#include file="conn_fj16.asp" -->
<%
ID=trim(request("ID"))
if  ID=""  then
response.Write "<script language=javascript>{window.alert('您尚未登录或登录超时,请重新登录!');window.location.href='index.asp';}</script>"
response.end
end if
sql="select * from admin156  where ID="&ID&""
set rs=server.CreateObject("adodb.recordset")
rs.open sql,conn,1,2
%>
<%

oldpwd=trim(request("oldpwd"))
newpwd=trim(request("newpwd"))
newpwd2=trim(request("newpwd2"))

if newpwd<>""and newpwd2<>"" then 
    if newpwd<>newpwd2  then 
			     response.Write "<script language=javascript>{window.alert('报错:您两次输入的新密码不一致!');window.history.go(-1);}</script>"
				 response.End
				 end if
if oldpwd="" then 
response.Write "<script language=javascript>{window.alert('报错:在修改新密码前必须输入原密码!');window.history.go(-1);}</script>"
response.End
   else 
   if oldpwd<>rs("pwd") then 
	 response.Write "<script language=javascript>{window.alert('报错:您输入的原密码错误,要修改密码必须核实原密码!');window.history.go(-1);}</script>"
	 response.End
end if
end if
if len(newpwd)<6 or len(newpwd)>20 then
response.Write "<script language=JavaScript>{window.alert('报错:您的密码长度不够,至少要输入六位,最长不超过20位!');window.history.go(-1);}</script>"
response.End()
   end if
rs("pwd")=newpwd
rs.update
response.Write "<script language=JavaScript>{window.alert('恭喜您,密码修改成功!下次登录时请用新密码!');window.history.go(-1);}</script>"
end if

%>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312" />
<link href="Images/Style.css" rel="stylesheet" type="text/css">
<title>修改用户</title>
<style type="text/css">
<!--
.STYLE5 {color: #000000}
.STYLE15 {font-size: 14; color: #FF0000; }
.STYLE7 {font-size: 12px; color: #0000FF; }
-->
</style>
</head>

<body>
<br>
<br>
<table class=tableBorder width="95%" border=0 align="center" cellpadding=5 cellspacing=1>
    <tbody>
      <tr>
        <th width="100%" height=21 sytle="line-height:150%"><span class="STYLE4">【修改密码】</span></th>
      </tr>
      <tr>
        <td  class=forumRow>
<form id="form1" name="form1" method="post" action="admin_uppwdself.asp">
  <label></label>
  <p>
  <label>
    <div align="center">
     <table width="545" border="1" align="center" cellpadding="3" cellspacing="1" bordercolor="#F3F3F3" style="border-collapse: collapse">
      <tr>
        <td width="112" class="STYLE5">用户名:</td>
        <td width="407"><label><%=rs("yonghuming")%>   <span class="STYLE7">--姓名不可以修改--</span></label></td>
      </tr>
      <tr>
        <td class="STYLE4"><span class="STYLE15">原密码:</span></td>
        <td><input name="oldpwd" type="password" id="oldpwd">
        <span class="STYLE7">在修改密码前必须输入原密码</span></td>
      </tr>
      <tr>
        <td class="STYLE4"><span class="STYLE15">新密码:</span></td>
        <td><input name="newpwd" type="password" id="newpwd">
        <span class="STYLE7">新密码可以是字母、数字和符号的组合</span></td>
      </tr>
      <tr>
        <td class="STYLE4"><span class="STYLE15">再次输入新密码:</span></td>
        <td><input name="newpwd2" type="password" id="newpwd2">
        <span class="STYLE7">新密码确认</span></td>
      </tr>
      <tr>
        <td class="STYLE4">真实姓名</td>
        <td><%=rs("xingming")%></td>
      </tr>
      <tr>
        <td class="STYLE5">访问级别</td>
        <td><%if rs("jibie")="0" then response.Write "普通浏览用户(只读)"%><%if rs("jibie")="1" then response.Write "系统管理员(员工增删减)"%><%if rs("jibie")="2" then response.Write "最高级管理员(系统维护)"%></td>
      </tr>
    </table>
  <p align="center">
    <input type="submit" name="Submit" value="修改密码" />
    <input name="ID" type="hidden" id="ID" value="<%=rs("ID")%>">
  </p>
    </label>
</form>
</td>
      </tr>
    </tbody>
  </table>
</body>
</html>

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -