<!--#include file="conn.asp"-->
<%
user=trim(request.form("user"))      
pwd=trim(request.form("pwd"))%>
<%if user<>"" and pwd<>"" then%>

<%
if request("edit")="ok" then
set rsmag=server.createobject("adodb.recordset")
sqlmag="select * from user where username='"&user&"'"
rsmag.open sqlmag,conn,1,1
if not rsmag.eof then
 if pwd=rsmag("password") then
%>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">

<title>修改资料</title>
<%
  set rs1=server.createobject("adodb.recordset")
sql="select * from user where username='" & user &"'"
rs1.Open SQL,conn,1,2
if rs1.BOF or rs1.EOF then
kind=5
else
kind=rs1("kind")
webname=rs1("web")
end if
set rs1=nothing
rs1.close
%>
<link rel="stylesheet" type="text/css" href="style/<%=kind%>.css">
</head>
<table width="600" align="center" cellspacing="0" cellpadding="1"  border="0" bgcolor=#000000>
  <tr> 
    <td> 
      <table width="600" cellspacing="0" cellpadding="4" border="0" class="table002">
        <tr> 
          <td class="jnfont7" valign="middle" align=left> <b>>> </b> <a href="<%=web%>"><acronym title="返回主页">主页</acronym></a> 
            | <a href="modify.asp?user=<%=user%>"><acronym title="编辑你的个人资料">修改资料</acronym></a> 
            | <%if  adminok="ok" then%><a href="usermanager.asp?user=<%=user%>&exit=ok"><acronym title="退出管理">退出管理</acronym></a><%else%><a href="usermanager.asp?user=<%=user%>"><acronym title="回复或删除留言">留言管理</acronym></a><%end if%> 
            | <a href="default.asp"><acronym title="免费申请留言本">免费申请</acronym></a> 
            | <a href="top.asp"><acronym title="留言排行榜">留言排行</acronym></a> </td>
          <td class="jnfont7" valign="middle" align=right><b><%=webname%></b></td>
        </tr>
      </table>
    </td>
  </tr>
</table>
<p align="center">&nbsp;</p>
<table border="0" width="600" bgcolor="#000000" cellspacing="1" cellpadding="3" align="center">
  <form action="modifyok.asp" method="POST">          
      <tr class="table001">          
        <td width="20%" align="right"><table class="jnfont7">用户名：</table></td>          
        <td width="80%">           
               <%=rsmag("username")%>      
               <input type="hidden" name="user"  value="<%=rsmag("username")%>"></td>                     
      </tr>                     
      <tr class="table001">                     
        <td width="20%" align="right"><table class="jnfont7">密码：</table></td>                      
        <td width="80%">                       
                <input type="text" name="pass" size="20" maxlength="15" class="input1" value="<%=rsmag("password")%>">                      
                * 1-15个字节</td>                     
      </tr>                                  
      <tr class="table001">                     
        <td width="20%" align="right"><table class="jnfont7">站长姓名：</table></td>                     
        <td width="80%"><input type="text" size="20" maxlength="100"  class="input1" name="zhanzhang" value="<%=rsmag("webmaster")%>">                     
          *</td>                       
      </tr>
      <tr class="table001">                     
        <td width="20%" align="right"><table class="jnfont7">留言样式：</table></td>                     
        <td width="80%">         <select name="kind" size="1">
<OPTION selected VALUE="<%=rsmag("kind")%>"><%=rsmag("kind")%>
<OPTION VALUE="1">金壁辉煌
<OPTION VALUE="2">粉红回忆
<OPTION VALUE="3">银灰世界
<OPTION VALUE="4">菁菁校园
<OPTION VALUE="5">白色如雪

</select>                  </td>                       
      </tr>        
      <tr class="table001">                     
        <td width="20%" align="right" ><table class="jnfont7">E-mail：</table></td>                     
        <td width="80%"><input type="text" size="50" maxlength="100" name="email" class="input1" value="<%=rsmag("email")%>">                     
          *</td>                       
      </tr>                       
      <tr class="table001">                       
        <td width="20%" align="right" ><table class="jnfont7">站&nbsp; 名：</table></td>                     
        <td width="80%"><input type="text" size="50" maxlength="20" name="web"  class="input1" value="<%=rsmag("web")%>">                     
          *</td>                     
      </tr>                     
      <tr class="table001">                     
        <td width="20%" align="right" ><table class="jnfont7">主页地址：</table></td>                     
        <td width="80%"><input type="text" name="url" size="50" maxlength="100"  class="input1" value="<%=rsmag("wwwhttp")%>">
          *</td>                     
      </tr>             
      <tr class="table001">                     
        <td width="20%" align="right" ><table class="jnfont7">主页简介：</table></td>                    
        
        <td width="80%" ><textarea cols="46" type="text" name="intro" rows="4"  class="testarea1"><%=rsmag("wwwintro")%></textarea>                    
                             
        </td>                   
      </tr>                   
      <tr class="table003">                   
        <td width="20%" colspan="2" align="right">                   
          <p align="center"><input type="submit" value="写完了" class="input1">                    
          <input type="reset" value="重新写" name="reset" class="input1">                   
        </td>                   
      </tr>                         
      </form>              
    </table>
<table border="0" width="560" cellpadding="0" align="center">
  <tr> 
    <td width="100%"> 
      <hr size="1" width="80%">
    </td>
  </tr>
  <tr> 
    <td width="100%" class="jnfont3"> 
      <p align="center">辉煌多用户留言本系统V1.0<br>
        哈尔滨信息港免费提供 
    </td>
  </tr>
</table>
<p>&nbsp;</p>
</body> 
</html>        
   <%
 else
   response.write("<script>alert('密码不对哦！');history.go(-1)</script>")
 end if
else

  response.write("<script>alert('用户名不对 ');history.go(-1)</script>")
rsmag.close
set rsmag=nothing  
conn.close
set conn=nothing
end if
end if
else%>

<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">

<title>修改资料</title>
<%user=Request.QueryString("user")
  set rs1=server.createobject("adodb.recordset")
sql="select * from user where username='" & user &"'"
rs1.Open SQL,conn,1,2
if rs1.BOF or rs1.EOF then
kind=5
else
kind=rs1("kind")
webname=rs1("web")
end if
set rs1=nothing
rs1.close
conn.close
set conn=nothing%>
<link rel="stylesheet" type="text/css" href="style/<%=kind%>.css">
</head>
<body topmargin="6">
<table width="600" align="center" cellspacing="0" cellpadding="1"  border="0" bgcolor=#000000>
  <tr> 
    <td> 
      <table width="600" cellspacing="0" cellpadding="4" border="0" class="table002">
        <tr> 
          <td class="jnfont7" valign="middle" align=left> <b>>> </b> <a href="<%=web%>"><acronym title="返回主页">主页</acronym></a> 
            | <a href="modify.asp?user=<%=user%>"><acronym title="编辑你的个人资料">修改资料</acronym></a> 
            | <%if  adminok="ok" then%><a href="usermanager.asp?user=<%=user%>&exit=ok"><acronym title="退出管理">退出管理</acronym></a><%else%><a href="usermanager.asp?user=<%=user%>"><acronym title="回复或删除留言">留言管理</acronym></a><%end if%> 
            | <a href="default.asp"><acronym title="免费申请留言本">免费申请</acronym></a> 
            | <a href="top.asp"><acronym title="留言排行榜">留言排行</acronym></a> </td>
          <td class="jnfont7" valign="middle" align=right><b><%=webname%></b></td>
        </tr>
      </table>
    </td>
  </tr>
</table>
<p align="center">&nbsp;</p>        
          <table border="0" cellspacing="1" cellpadding="0" bgcolor="#000000" width="150" align="center">         
            <tr class="table003">         
              <td width="50%" align="center" ><table class="jnfont7" align="center">修改资料</table></td>         
            </tr>         
            <tr class="table001">         
              <td width="50%" valign="top">                                                                                   
          <table border="0" width="100%" cellspacing="1" cellpadding="0">
            <form method="POST" action="modify.asp?edit=ok">
            <tr>
              <td width="100%" class="jnfont3">
                <p align="center">用户名：<input name="user" size="13" maxlength="20" class="input1"value="<%=request("user")%>"><br>
              密&nbsp; 码：<input name="pwd" size="13" maxlength="20" class="input1" type="password">                                                                                    
                <br>   
                                                                                                      
            <input type="submit" value=" 登 陆 " name="cmdOk" class="input1" >                                                                                         
                </p>    
              </td>     
            </tr>     
            <tr>     
              <td width="100%" class="jnfont3">     
                <p align="center">                                                                                        
                 『<a href="guestbook.asp?user=<%=request("user")%>">返回</a>』</font></p>                                                                                       
              </td>     
            </tr>                 
            </form>    
          </table>   
          </table>           
<p align="center">&nbsp;</p>                     
<table border="0" width="560" cellpadding="0" align="center">
  <tr> 
    <td width="100%"> 
      <hr size="1" width="80%">
    </td>
  </tr>
  <tr> 
    <td width="100%" class="jnfont6"> 
          <p align="center">
            <a href=http://www.5151.cn target=_blank>免费留言本由[中泰科技]提供</a>
        </td>
      </tr>
    </table>     
</body> 
</html>
<%end if%>