<%@ page contentType="text/html; charset=GBK"%>
<%@ page import="java.sql.*,gbase.db.*" %>
<%@ include file="../checkLogin.jsp" %>
<SCRIPT language="JavaScript" src="../js/util.js"></SCRIPT>
<%
DBOperation theDBOperation = new DBOperation();
String user_id = (String)session.getAttribute("user_id");

String sql = "select * from web_user where user_id='"+user_id+"'";
ResultSet rs =theDBOperation.getResultSet(sql);


if(!rs.next())
{
out.print("所取的结果集为空！");
}
%>
<html>
<head>
<title>
修改自身资料
</title>
</head>
<LINK href="../images/style.css" rel=stylesheet>
<body leftmargin="0" topmargin="0">

<!--导航-->
    <table border="0" cellpadding="0" cellspacing="0" width="100%">
       <tr>
		<td width="100%" height="20"  bgcolor="#eeeeee" class="p2">您当前所在的位置>>修改自身资料</td>
	   </tr>
       <tr>
          <td width="100%" height="2"> <img border="0" src="../images/spacer.gif" width="1" height="3"></td>
       </tr>
    </table>
<!--标题-->
  <div align="center">
   <table border="0" width="100%" cellspacing="0" cellpadding="0" height="34">
	<tr>
		<td width="159" background="../images/back_board2.gif" nowrap valign="bottom"><span class="title01">&nbsp;&nbsp;<span class="style1">修改自身资料</span></span></td>
		<td valign="bottom" align="right" width="642"></td>
	</tr>
	<tr>
		<td bgcolor="#2C9CC4" colspan="2"><img border="0" src="../images/bline_3.gif" width="1" height="2"></td>
	</tr>
</table>
</div><br>
<form name="form1" method="post" action="myuser_save.jsp">
<div align="center">
<table width="80%" class="p1" border="0" cellSpacing="1" cellPadding="3" align="center" bgColor="#cccccc">
        <tr>
		<td align="right"  bgColor=#e9f0f4>工号：</td>
		<td onmouseover='vbscript:me.bgcolor="#F5F5F5"'	onmouseout='vbscript:me.bgcolor="#FFFFFF"' bgColor=#ffffff>&nbsp;
			<%=rs.getString("user_account")%>
                        <input name="user_id" type="hidden" value="<%=rs.getString("user_id")%>">
		</td>
	</tr>
	<tr>
		<td align="right"  bgColor=#e9f0f4>姓名：</td>
		<td onmouseover='vbscript:me.bgcolor="#F5F5F5"'	onmouseout='vbscript:me.bgcolor="#FFFFFF"' bgColor=#ffffff>&nbsp;
			<input name="user_name" type="text" size="50" maxlength="25" value="<%=rs.getString("user_name")%>">&nbsp;<font color="#ff0000">*</font>
		</td>
	</tr>
	<tr>
		<td align="right"  bgColor=#e9f0f4>密码：</td>
		<td onmouseover='vbscript:me.bgcolor="#F5F5F5"'	onmouseout='vbscript:me.bgcolor="#FFFFFF"' bgColor=#ffffff>&nbsp;
			<input name="password" type="password" size="50" maxlength="25" value="<%=rs.getString("password")%>">&nbsp;<font color="#ff0000">*</font>
		</td>
	</tr>
	<tr>
		<td align="right"  bgColor=#e9f0f4>重复密码：</td>
		<td onmouseover='vbscript:me.bgcolor="#F5F5F5"'	onmouseout='vbscript:me.bgcolor="#FFFFFF"' bgColor=#ffffff>&nbsp;
			<input name="password1" type="password" size="50" maxlength="25"  value="<%=rs.getString("password")%>">&nbsp;<font color="#ff0000">*</font>
		</td>
	</tr>
	
	<tr>
		<td align="right"  bgColor=#e9f0f4>联系电话：</td>
		<td onmouseover='vbscript:me.bgcolor="#F5F5F5"'	onmouseout='vbscript:me.bgcolor="#FFFFFF"' bgColor=#ffffff>&nbsp;
			<input name="telno" type="text" size="50" maxlength="25" value="<%=rs.getString("telno")%>">&nbsp;
		</td>
	</tr>
	<tr>
		<td align="right"  bgColor=#e9f0f4>职务：</td>
		<td onmouseover='vbscript:me.bgcolor="#F5F5F5"'	onmouseout='vbscript:me.bgcolor="#FFFFFF"' bgColor=#ffffff>&nbsp;
			<input name="duty" type="text" size="50" maxlength="25" value="<%=rs.getString("duty")%>">&nbsp;
		</td>
	</tr>
	<tr>
		<td align="right"  bgColor=#e9f0f4>籍贯：</td>
		<td onmouseover='vbscript:me.bgcolor="#F5F5F5"'	onmouseout='vbscript:me.bgcolor="#FFFFFF"' bgColor=#ffffff>&nbsp;
			<input name="bir_add" type="text" size="50" maxlength="25" value="<%=rs.getString("bir_add")%>">&nbsp;
		</td>
	</tr>
	
</table>

<table border="0" cellpadding="3" class="p1" width="90%" bordercolor="#D7D7D7" style="border-collapse: collapse" cellspacing="0">
	<tr>
		<td width="30%" align="right">　</td>
		<td width="70%" height="0">
			<img border="0" src="../images/btn/confirm.gif"  onclick = "check_validate(document.form1)" style="cursor:hand">
			<A href="javascript:document.form1.reset();"><IMG src="../images/btn/reset.gif" border=0></A>
			
		</td>
	</tr>
</table>
</div>
</form>
</body>
<Script Language="javaScript">
    function  check_validate(theForm) {
        if (isSpace(theForm.user_id.value)) {
            alert("工号不能为空！");
            theForm.user_id.focus();
            return false;
        }
        if (theForm.password.value!=theForm.password1.value) {
            alert("两次密码不一样！");
            theForm.password.focus();
            return false;
        }
        
        theForm.submit();
    }
    
</Script>
</html>
