<%@ include file="newindex.htm"%>
<%@ page import="java.sql.*" %>
<html>
  <head>
    <title></title>
    <script language="javascript" src="JS/form_valid.js"></script>
  </head>
    <body>
        <form action="editemp1.jsp" method="post" name="ctis" onsubmit="return checkEmpRegform()">
        <%!
        Connection con;
        Statement st;
        PreparedStatement pst;
        ResultSet rs;
        String eid,uname,pwd,fn,ln,email,mobile,addr,city,state,cntry;
        int i;
        %>
        <%
        uname=(String)session.getAttribute("uname");
        Class.forName("oracle.jdbc.driver.OracleDriver");
        con = DriverManager.getConnection("jdbc:oracle:thin:@localhost:1521:xe","c2t","c2t");
        st=con.createStatement();
        rs=st.executeQuery("select * from employee where uname='"+uname+"'");
        if(rs.next())
        {
                eid=rs.getString("eid");
                uname=rs.getString("uname");
                pwd=rs.getString("pwd");
                fn=rs.getString("fn");
                ln=rs.getString("ln");
                if(ln==null) ln="";
                email=rs.getString("email");
                mobile=rs.getString("mobile");
                addr=rs.getString("addr");
                city=rs.getString("city");
                state=rs.getString("state");
                cntry=rs.getString("cntry");
        }
        %>           
                <div style="position: absolute; width: 256px; height: 25px; z-index: 4; left: 293px; top: 249px" id="layer6">
				<b><font face="Arial" color="#F5A625" size="4">Welcome <%=uname%></font></b></div>
           
            <div style="position: absolute; width: 100px; height: 26px; z-index: 5; left: 975px; top: 498px" id="layer7">
	    <b><a href="login.jsp"><font face="Tahoma" size="2" color="#2D2E32">Logout</font></a></b></div>
           
        <div style="position: absolute; width: 562px; height: 191px; z-index: 6; left: 415px; top: 292px" id="layer8">
            <table border="0" width="100%" id="table1" height="191">
                <tr>
                    <td width="142"><font face="Trebuchet MS" size="2">User Name</font></td>
                    <td><font color="#2D2E32"><%=uname%><input type="hidden" name="uname" value="<%=uname%>" size="20"></font></td>
                    <td><font face="Trebuchet MS" size="2">Password</font></td>
                    <td><font color="#2D2E32"><input type="password" value="<%=pwd%>" name="pwd" size="20"><input type="hidden" value="<%=eid%>" name="eid" size="20"></font></td>
                </tr>
                <tr>
                    <td width="142"><font face="Trebuchet MS" size="2">First Name</font></td>
                    <td><font color="#2D2E32"><input type="text" name="fn" value="<%=fn%>" size="20"></font></td>
                    <td><font face="Trebuchet MS" size="2">Last Name</font></td>
                    <td><font color="#2D2E32"><input type="text" name="ln" value="<%=ln%>" size="20"></font></td>
                </tr>
                <tr>
                    <td width="142"><font face="Trebuchet MS" size="2">Email </font></td>
                    <td><font color="#2D2E32"><input type="text" name="email" value="<%=email%>" size="20"></font></td>
                    <td><font face="Trebuchet MS" size="2">Mobile</font></td>
                    <td><font color="#2D2E32"><input type="text" name="mobile" value="<%=mobile%>" size="20"></font></td>
                </tr>
                <tr>
                    <td width="142"><font face="Trebuchet MS" size="2">Address</font></td>
                    <td><font color="#2D2E32"><input type="text" name="addr" value="<%=addr%>" size="20"></font></td>
                    <td><font face="Trebuchet MS" size="2">City</font></td>
                    <td><font color="#2D2E32"><input type="text" name="city" value="<%=city%>" size="20"></font></td>
                </tr>
                <tr>
                    <td width="142"><font face="Trebuchet MS" size="2">State</font></td>
                    <td><font color="#2D2E32"><input type="text" name="state" value="<%=state%>" size="20"></font></td>
                    <td><font face="Trebuchet MS" size="2">Country</font></td>
                    <td><font color="#2D2E32"><input type="text" name="cntry" value="<%=cntry%>" size="20"></font></td>
                </tr>
                <tr>
                    <td width="142">&nbsp;</td>
                    <td>&nbsp;</td>
                    <td>&nbsp;<input type="submit" value="Update Changes" name="B1" style="float: right"></td>
                    <td>&nbsp;</td>
                </tr>
            </table>
        </div>
           
            <div style="position: absolute; width: 31px; height: 18px; z-index: 7; left: 970px; top: 235px" id="layer10">
				<b><a href="emplogin.jsp">
				<font face="Tahoma" size="2" color="#2D2E32">Back</font></a></b></div>
           
            <p>&nbsp;</p>
        </form>
    </body>
</html>