<!-- #include file="conn.asp "-->
<!--#include file="checkUser.asp"-->
<%
if Request("modifyPassword")=1 then
	if Request("password1")<>Request("password2") then
		response.write "<script>alert('注意：确认密码与密码不相同!');location.href='useradd.asp';</script>"
		response.End
	end if
	modifyPassword=1
end if
'	response.write modifyPassword
'	response.End
       Set cmdTemp = Server.CreateObject("ADODB.Command")
       Set InsertCursor = Server.CreateObject("ADODB.Recordset")
       cmdTemp.CommandText = "SELECT * FROM admin WHERE id="&Request("id")
       cmdTemp.CommandType = 1
       Set cmdTemp.ActiveConnection = conn
       InsertCursor.Open cmdTemp, , 1, 3
 
       InsertCursor("admin") =Request("admin")
if modifyPassword=1 then
       InsertCursor("pwd") =Request("password1")
end if
       InsertCursor.Update
       InsertCursor.close
	   conn.close
       set InsertCursor=nothing
       set conn=nothing
%>
<script language=Javascript>
<!--
alert("修改成功！");
this.document.location="main.asp";
-->
</script>
