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

📄 admin_admin_information.asp

📁 Art2008 CMS是一款具有强大的功能的基于ASP语言的网站管理软件
💻 ASP
📖 第 1 页 / 共 2 页
字号:
    Exit Function
  End If

  If (Len(theForm.password1.value) > 20) Then
    MsgBox "在 新密码 域中,请最多输入 20 个字符。", 0, "有效性验证错误"
    theForm.password1.focus()
    FrontPage_Form1_onsubmit = False
    Exit Function
  End If

  If (theForm.password2.value = "") Then
    MsgBox "请在 确认新密码 域中输入值。", 0, "有效性验证错误"
    theForm.password2.focus()
    FrontPage_Form1_onsubmit = False
    Exit Function
  End If

  If (Len(theForm.password2.value) < 5) Then
    MsgBox "在 确认新密码 域中,请至少输入 5 个字符。", 0, "有效性验证错误"
    theForm.password2.focus()
    FrontPage_Form1_onsubmit = False
    Exit Function
  End If

  If (Len(theForm.password2.value) > 20) Then
    MsgBox "在 确认新密码 域中,请最多输入 20 个字符。", 0, "有效性验证错误"
    theForm.password2.focus()
    FrontPage_Form1_onsubmit = False
    Exit Function
  End If
  FrontPage_Form1_onsubmit = True 
End Function
--></script>
<%
Dim username:username=chkhtm(trim(request("username")))
Dim oldpassword:oldpassword=chkhtm(trim(request("oldpassword")))
Dim password1:password1=trim(request("password1"))
Dim password2:password2=trim(request("password2"))
Dim ID:ID=trim(request("ID"))

if (not isNumeric(ID)) then
	id=""
end if

if username<>"" and id<>"" and oldpassword<>"" and password1<>"" and password2<>"" then
	if password1<>password2 then
		call ArtErr("<li>两次新密码不一样,请重新填写</li>","1")
	end if
	password1=md5(password1)
	oldpassword=md5(oldpassword)
	
	set rs = Server.CreateObject("ADODB.RecordSet")
	rs.Open "select * from [admin] where [ID]="&ID&" and [pass]='"&oldpassword&"' order by id desc",conn,1,3
	if rs.recordcount=0 then
		call ArtErr("<li>旧密码输入不正确,请重新填写</li>","1")
	else
		rs("user")=username
		rs("pass")=password1
		Response.Cookies(Art2008)("adminuser")=""
		Response.Cookies(Art2008)("adminpass")=""
		rs.update
	call ArtErr("<li>恭喜您!您的新密码修改成功!</li><li>请记住您的新密码,系统需要重新登陆!</li>","2")
	end if
	rs.close:set rs=nothing
end if
						
sql = "select * from [admin] where [user]='"&Request.Cookies(Art2008)("adminuser")&"'"
Set rs = Server.CreateObject("ADODB.RecordSet")
rs.Open sql,conn,1,1

photo=trim(rs("photo"))

%>
</head>

     <table cellpadding="2" cellspacing="1" border="0" width="95%" class="tableBorder"    align=center>   
         <tr>
         <th height="25"><font color="red"><%=rs("fullname")%></font><strong>修改资料</strong></th>
        </tr>
       </TABLE>
         <table width="100%" border="0" align="center" cellpadding="2" cellspacing="1" class="table" > 
 		  <form method="POST" action="?id=<%=rs("id")%>" name="FrontPage_Form1">
           <tr bgcolor="#E9EAF3" onMouseOut="this.style.backgroundColor='#E9EAF3';this.style.color='black';" onMouseOver="this.style.backgroundColor='#6188D7';this.style.color='white';">
              <td width=29% align=left><b><u>用 户 名:</u></b></td>
              <td width="45%" align=left><input name="username" size="27" value="<%=rs("user")%>" class="Input_1" maxlength="30" style="font-family: 宋体; font-size: 9pt" ></td>
              <td width="26%" rowspan="6" align="center" class="forumRaw">
			  <table border="0" align="center"  cellpadding="0" cellspacing="0">
                <tr>
                  <td align="center">
                  
                  <SCRIPT LANGUAGE="JavaScript">
                    document.write('<img  border=1  src=\"<%if not isnull(photo) and  photo<>"" then response.write "../"&photo&"" else response.write "../images/pic.gif"  end if%>\" onload=\"if((this.width/this.height)>(3/4)){this.width=150;}else{this.height=250;}\">');
                  </SCRIPT>                  
                  </td>
                </tr>
              </table>
			</td>
            </tr>
			<tr bgcolor="#E9EAF3" onMouseOut="this.style.backgroundColor='#E9EAF3';this.style.color='black';" onMouseOver="this.style.backgroundColor='#6188D7';this.style.color='white';">
              <td width=29% align=left ><b><u>旧密码:</u></b><br><font color="#FF0000">修改密码前必须输入原始密码,不能少于5个字符</font></td>
              <td ><input type="password" name="oldpassword" size="30" maxlength="20"></td>
            </tr>
            <tr bgcolor="#E9EAF3" onMouseOut="this.style.backgroundColor='#E9EAF3';this.style.color='black';" onMouseOver="this.style.backgroundColor='#6188D7';this.style.color='white';">
              <td width=29% align=left ><b><u>新密码</u></b><br><font color="#FF0000">不能少于5个字符</font></td>
              <td ><input type="password" name="password1" size="30" maxlength="20"></td>
            </tr>
            <tr bgcolor="#E9EAF3" onMouseOut="this.style.backgroundColor='#E9EAF3';this.style.color='black';" onMouseOver="this.style.backgroundColor='#6188D7';this.style.color='white';">
              <td width=29% align=left><b><u>确认新密码:</u></b><br><font color="#FF0000">不能少于5个字符</font></td>
              <td ><input type="password" name="password2" size="30" maxlength="20"></td>			  
            </tr>
			<tr bgcolor="#E9EAF3">
			<td align="center" colspan="2"><input type="submit" value=" 提 交 " name="B1">   <input type="reset" value=" 重 置 " name="B2"></td></tr>
			</form>
			
			</table>
            
            <table width="100%" border="0" align="center" cellpadding="2" cellspacing="1" class="table" >            
            <form method="POST" name="FrmAddLink" LANGUAGE="javascript" onsubmit="return FrmAddLink_onsubmit()"  action="?Action=information&id=<%=rs("id")%>">           
		    <tr bgcolor="#FFFFFF" onMouseOut="this.style.backgroundColor='#FFFFFF'" onMouseOver="this.style.backgroundColor='#D7E3F3'">
              <td width=29% ><b><u>提示问题:</u></b><br><font color="green">忘记密码后,可以通过设置的问题和答案找回密码。</font></td>
              <td ><input name="question" size="26" class="Input_1" maxlength="50" style="font-family: 宋体; font-size: 9pt" type="text" value="<%=rs("question")%>"></td>
            </tr>
            <tr bgcolor="#F7F7F7" onMouseOut="this.style.backgroundColor='#F7F7F7'" onMouseOver="this.style.backgroundColor='#D7E3F3'">
              <td width=29% align=left ><b><u>问题答案:</u></b><br>提示问题与答案不能一样</td>
              <td ><input name="answer" type="text" size="26" onmouseover=this.focus() onfocus=this.select()  onclick="if(this.value=='<%=rs("answer")%>')this.value=''" value="<%=rs("answer")%>" class="Input_1"   style="font-family: 宋体; font-size: 9pt"></td>
            </tr>
            <tr bgcolor="#FFFFFF" onMouseOut="this.style.backgroundColor='#FFFFFF'" onMouseOver="this.style.backgroundColor='#D7E3F3'">
              <td width=29% align=left ><b><u>真实姓名:</u></b><br><FONT color=#ff5500>姓名必须是1-10个字</FONT> </td>
              <td><input name="fullname" size="15" class="Input_1" maxlength="10" style="font-family: 宋体; font-size: 9pt" value="<%=rs("fullname")%>">&nbsp;&nbsp;&nbsp;<INPUT type=radio <%if rs("sex") ="先生" then Response.Write "checked"%> value="先生" name="sex"> <FONT class=f2>先生&nbsp; <INPUT type=radio <%if rs("sex") ="女士" then Response.Write "checked"%>  value="女士" name="sex"> 女士&nbsp; <INPUT type=radio <%if rs("sex") ="保密" then Response.Write "checked"%>  value="保密" name="sex"> 保密</td>
            </tr>
            <tr bgcolor="#F7F7F7" onMouseOut="this.style.backgroundColor='#F7F7F7'" onMouseOver="this.style.backgroundColor='#D7E3F3'">
              <td width=29% align=left ><b><u>生&nbsp;&nbsp;&nbsp; 日:</u></b></td>
              <td><select size="1" name="birthyear" style="font-family: 宋体; font-size: 9pt">
                <%for i=1940 to 2000%>
                <option <%if rs("birthyear")=i then%>selected<%end if%> value="<%=i%>"><%=i%></option>
                <%next%>
              </select>
                <select size="1" name="birthmonth" style="font-family: 宋体; font-size: 9pt">
                  <%for i=1 to 12%>
                  <option <%if rs("birthmonth")=i then%>selected<%end if%> value="<%=i%>"><%=i%></option>
                  <%next%>
                </select>
                <select size="1" name="birthday" style="font-family: 宋体; font-size: 9pt">
                  <%for i=1 to 31%>
                  <option <%if rs("birthday")=i then%>selected<%end if%> value="<%=i%>"><%=i%></option>
                  <%next%>
                </select>
              日</td>
            </tr>
            <tr bgcolor="#F7F7F7" onMouseOut="this.style.backgroundColor='#F7F7F7'" onMouseOver="this.style.backgroundColor='#D7E3F3'">
              <td width=29% align=left ><b><u>工作单位</u></b>:</td>
              <td >               
                <input name="depname" size="26" class="Input_1" maxlength="50" style="font-family: 宋体; font-size: 9pt" value="<%=rs("depname")%>"></td>
            </tr>
            <tr bgcolor="#FFFFFF" onMouseOut="this.style.backgroundColor='#FFFFFF'" onMouseOver="this.style.backgroundColor='#D7E3F3'">
              <td width=29% align=left ><b><u>联系电话:</u></b></td>
              <td><input name="tel" size="26" class="Input_1" maxlength="100" style="font-family: 宋体; font-size: 9pt" value="<%=rs("tel")%>"></td>
            </tr>
            <tr bgcolor="#F7F7F7" onMouseOut="this.style.backgroundColor='#F7F7F7'" onMouseOver="this.style.backgroundColor='#D7E3F3'">
              <td width=29% align=left ><b><u>电子邮件:</u></b></td>
              <td><input name="email" size="26" class="Input_1" maxlength="100" style="font-family: 宋体; font-size: 9pt" value="<%=rs("email")%>"></td>
            </tr>
            <tr bgcolor="#FFFFFF" onMouseOut="this.style.backgroundColor='#FFFFFF'" onMouseOver="this.style.backgroundColor='#D7E3F3'">
              <td width=29% align="left" ><b><u>个人照片:</u></b><br>上传照片时注意尺寸大小<br><font color="#FF0000">如:宽:120 高:150</font></td>
              <td><iframe name="ad" frameborder=0 width=100% height=25 scrolling=no src=uploadface.asp></iframe>
                  <input id="photo" name="photo" size="26" class="Input_1" maxlength="255" style="font-family: 宋体; font-size: 9pt" value="<%=rs("photo")%>" title="个人照片。您可以上传自己的照片,也可以直接填写您的网上照片的地址。">
                  &nbsp;<input type="button" name="Button" value="从已上传图片选择" onClick="javascript:window.open('selectupfile.asp?UrlID=2', 'selupfile', 'width=800, height=600, toolbar=no, menubar=no, scrollbars=yes, resizable=no, location=no, status=yes');" style="cursor: hand;background-color:#DEDDEA"></td>
            </tr>
            <tr bgcolor="#F7F7F7" onMouseOut="this.style.backgroundColor='#F7F7F7'" onMouseOver="this.style.backgroundColor='#D7E3F3'">
              <td width=29% align=left ><b><u>自我介绍:</u></b><br>
			  <LI><FONT color=#ff0000>请不要反复复制。</FONT> 
              <LI>不要使用广告词,不要加图片及Html代码。 </LI></td>
              <td><textarea rows="5" name="content" cols="60" style="font-family: 宋体; font-size: 9pt"  title="请在这里填写您的个人介绍。"><%=rs("content")%></textarea></td>
            </tr>
        <tr>
          <td class="forumRaw" align="center" colspan="2"><input type="submit" value="修 改"  name="cmdok" >       <input type="reset" value="复 原"  name="cmdcancel" >          <input type="reset" value="返 回" onclick="javascript:history.go(-1)" ></td>
        </tr></form>       
	  </table>
	  <%
rs.close:set rs=nothing
End Sub
%>




⌨️ 快捷键说明

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