<%
Act = Request.QueryString("act")
If act = "save" Then
loginpwd = TextEnCode(Request.Form("loginpwd"))
loginpwd1 = TextEnCode(Request.Form("loginpwd1"))
loginname = TextEnCode(Request.Form("loginname"))
Set Rs = Server.CreateObject("ADODB.RecordSet")
Rs.Open "Select loginpwd,loginname From login Where id="&Load_Session("loginid"),Conn,1,3
If Not Rs.Bof And Not Rs.Eof Then
If MD5(loginpwd)<>Rs(0) Then Response.Write "":Rs.Close:Set Rs=Nothing:Conn.Close:Set Conn=Nothing:Response.End
If loginpwd1<>"" Then Rs(0) = MD5(loginpwd1):Rs(1) = loginname
Rs.Update:Rs.Close:Set Rs=Nothing:Conn.Close:Set Conn=Nothing
Add_Session "loginname",loginname
Else
Response.Write "":Rs.Close:Set Rs=Nothing:Conn.Close:Set Conn=Nothing:Response.End
End If
Response.Write ""
Response.End
End If 'end save
Set Rs=Server.CreateObject("ADODB.RecordSet")
Rs.Open "Select loginlasttime,loginlastip,loginthistime,loginthisip,powercontent,logincount From login Left Join power On power.id=login.loginpower Where login.id="&Load_Session("loginid"),Conn,1,1
If Not Rs.Bof And Not Rs.Eof Then
loginlasttime=Rs(0):loginlastip=Rs(1):loginthistime=Rs(2):loginthisip=Rs(3):powercontent=Rs(4):logincount=Rs(5)
Rs.Close:Set Rs=Nothing:Conn.Close:Set Conn=Nothing
Else
Response.Write "":Rs.Close:Set Rs=Nothing:Conn.Close:Set Conn=Nothing:Response.End
End If
%>