?? getpwd3.asp
字號(hào):
<!--#include file="conn.asp"-->
<%response.buffer="True"%>
<!--#include file="md5.asp"-->
<script language="JavaScript">
<!--
function get_onsubmit() {
if (document.get.userid.value=="")
{
alert("請?jiān)O(shè)定您的登陸名。")
document.get.userid.focus()
return false
}
}
// -->
</script>
<meta http-equiv="Content-Language" content="zh-cn">
<link href="css.CSS" rel="stylesheet" type="text/css">
<title>密碼找回</title>
<style>
<!--
.style1 {
font-size: 16px;
font-family: "黑體";
}
-->
</style>
</head>
<% dim fpass1,fpass,strSql
if request.querystring("action")="edit" then
username=trim(request.querystring("username"))
fpass1=trim(request.form("fpass1"))
fpass=md5(fpass1)
set rs=server.CreateObject("adodb.recordset")
rs.Open "select * from [tt_link] where username='"&username&"'",conn,1,3
if rs.eof or rs.bof then
response.write "<li>參數(shù)錯(cuò)誤!"
response.end
end if
rs("password")=fpass
rs.update
rs.close
set rs=nothing
response.write "<script>alert('密碼修改成功,請記住!');history.back();</Script>"
response.end
end if%>
<%dim sql,rs,username,answer1,answer
if Request.form("submit") <> "" then
username=request.querystring("username") '頁面之間傳遞參數(shù)
answer1= trim(Request.form("answer1"))
set rs=server.createobject("adodb.recordset")
sql="select * from [tt_link] where username='"&UserName&"'"
rs.open sql,conn,1,1
answer =rs("answer")
answer1=md5(answer1)
rs.close
set rs=nothing
if answer<>answer1 then
response.write "<script>alert('你的答案錯(cuò)誤,請返回檢查!');history.back();</Script>"
response.end
else
end if
end if
%>
<center>
<script language="VBScript">
<!--
function checkaddurl()
fpass1=urlform.fpass1.value
if urlform.fpass1.value="" or len(fpass1)<4 or len(fpass1)>12 then
msgbox"請輸入新密碼(限4--12個(gè)字符)^_^"
urlform.fpass1.focus
elseif urlform.fpass1.value<>"" and urlform.fpass2.value<>urlform.fpass1.value then
msgbox"確認(rèn)密碼不相同!^_^"
urlform.fpass2.focus
else
urlform.submit
end if
end function
-->
</script>
<body topmargin="0" leftmargin="0">
<table border="0" cellpadding="0" cellspacing="0" style="border-collapse: collapse" bordercolor="#111111" width="400" id="AutoNumber1" height="147">
<tr>
<td width="500" height="25" bgcolor="#FF9900"> <p align="center"> ..:::第三步:請?jiān)O(shè)置你的新密碼:::...</td>
</tr>
<tr>
<td width="500" height="122">
<table border="0" width="100%" id="table1" height="100">
<form name="urlform" method="post" action="getpwd3.asp?action=edit&UserName=<%=UserName%>" onsubmit="return(search4())" >
<tr valign="baseline">
<td nowrap align="right" class=tdc><span class="style1">輸入新密碼:</span></td>
<td class=tdc>
<input type="password" name="fpass1" value="" size="20" maxlength="12">(4-12字符內(nèi))
</td>
</tr>
<tr valign="baseline">
<td nowrap align="right" class=tdc><span class="style1">密碼確認(rèn):</span></td>
<td class=tdc>
<input type="password" name="fpass2" value="" size="20" maxlength="12">(4-12字符內(nèi))
</td>
</tr>
<tr valign="baseline">
<td nowrap align="right" class=tdc> </td>
<td class=tdc>
<input type="button" name="sss" value="提交" onclick=checkaddurl()>
<input type="button" name="aaa" value="取消" onClick="javascript:window.close()">
</td>
</tr></form>
</table>
</td>
</tr>
</table>
<table border="0" width="400" id="table2" bgcolor="#FF9900">
<tr>
<td> </td>
</tr>
</table>
?? 快捷鍵說明
復(fù)制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號(hào)
Ctrl + =
減小字號(hào)
Ctrl + -