?? modipwd.aspx
字號:
?<!--#include file = "private.aspx"-->
<%
'######################################
' eWebEditor v4.00 - Advanced online web based WYSIWYG HTML editor.
' Copyright (c) 2003-2007 eWebSoft.com
'
' For further information go to http://www.ewebsoft.com/
' This copyright notice MUST stay intact for use.
'######################################
%>
<%
sPosition = sPosition & "修改用戶名及密碼"
Call Header()
Call Content()
Call Footer()
%>
<script language="vb" runat="server">
Sub Content()
Select Case sAction
Case "MODI"
Call DoModi()
Case Else
Call ShowForm()
End Select
End Sub
Sub ShowForm()
Response.Write ("<script language=javascript>" & VBcrlf & _
"function checklogin() {" & VBcrlf & _
"var obj;" & VBcrlf & _
"obj=document.myform.newusr;" & VBcrlf & _
"obj.value=BaseTrim(obj.value);" & VBcrlf & _
"if (obj.value=="""") {" & VBcrlf & _
"BaseAlert(obj, ""新用戶名不能為空!"");" & VBcrlf & _
"return false;" & VBcrlf & _
"}" & VBcrlf & _
"obj=document.myform.newpwd1;" & VBcrlf & _
"obj.value=BaseTrim(obj.value);" & VBcrlf & _
"if (obj.value=="""") {" & VBcrlf & _
"BaseAlert(obj, ""新密碼不能為空!"");" & VBcrlf & _
"return false;" & VBcrlf & _
"}" & VBcrlf & _
"if (document.myform.newpwd1.value!=document.myform.newpwd2.value){" & VBcrlf & _
"BaseAlert(document.myform.newpwd1, ""新密碼和確認密碼不相同!"");" & VBcrlf & _
"return false;" & VBcrlf & _
"}" & VBcrlf & _
"return true;" & VBcrlf & _
"}" & VBcrlf & _
"</s" & "cript>")
Response.Write ("<table border=0 cellspacing=1 align=center class=navi>" & _
"<tr><th><%=sPosition%></th></tr>" & _
"</table>")
Response.Write ("<br>")
Response.Write ("<table border=0 cellspacing=1 align=center class=form>" & _
"<form action='?action=modi' method=post name=myform onsubmit=""return checklogin()"">" & _
"<tr>" & _
"<th>設置名稱</th>" & _
"<th>基本參數設置</th>" & _
"<th>設置說明</th>" & _
"</tr>" & _
"<tr>" & _
"<td width=""15%"">新用戶名:</td>" & _
"<td width=""55%""><input type=text class=input size=20 name=newusr value=""" & inHTML(Session("eWebEditor_User")) & """></td>" & _
"<td width=""30%""><span class=red>*</span> 舊用戶名:<span class=blue>" & outHTML(Session("eWebEditor_User")) & "</span></td>" & _
"</tr>" & _
"<tr>" & _
"<td width=""15%"">新 密 碼:</td>" & _
"<td width=""55%""><input type=password class=input size=20 name=newpwd1 maxlength=30></td>" & _
"<td width=""30%""><span class=red>*</span></td>" & _
"</tr>" & _
"<tr>" & _
"<td width=""15%"">確認密碼:</td>" & _
"<td width=""55%""><input type=password class=input size=20 name=newpwd2 maxlength=30></td>" & _
"<td width=""30%""><span class=red>*</span></td>" & _
"</tr>" & _
"<tr><td align=center colspan=3><input type=submit name=bSubmit value="" 提交 ""></a> <input type=reset name=bReset value="" 重填 ""></td></tr>" & _
"</form>" & _
"</table>")
End Sub
Sub DoModi()
Dim sNewUsr, sNewPwd1, sNewPwd2
sNewUsr = Trim(Request("newusr"))
sNewPwd1 = Trim(Request("newpwd1"))
sNewPwd2 = Trim(Request("newpwd2"))
If sNewUsr = "" Then
GoError ("新用戶名不能為空!")
End If
If sNewPwd1 = "" then
GoError ("新密碼不能為空!")
End If
If sNewPwd1 <> sNewPwd2 Then
GoError ("新密碼和確認密碼不相同!")
End If
sUsername = sNewUsr
sPassword = sNewPwd1
Call WriteConfig()
Response.Write("<table border=0 cellspacing=1 align=center class=navi>" & _
"<tr><th>" & sPosition & "</th></tr>" & _
"</table>")
Response.Write ("<br>")
Response.Write ("<table border=0 cellspacing=1 align=center class=list>" & _
"<tr>" & _
"<td>登錄用戶名及密碼修改成功!</td>" & _
"</tr>" & _
"</table>")
End Sub
</script>
?? 快捷鍵說明
復制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號
Ctrl + =
減小字號
Ctrl + -