update_message.jsp~12~
上传用户:top0756
上传日期:2022-08-11
资源大小:6501k
文件大小:2k
源码类别:

Jsp/Servlet

开发平台:

VBScript

  1. <%@ page contentType="text/html; charset=GB2312" %>
  2. <%@ page import = "java.sql.*"%>
  3. <%@ page language = "java"%>
  4. <%@ page import = "proj112.ISOtoGb2312"%>
  5. <HTML>
  6. <HEAD>
  7. <TITLE>update</TITLE>
  8. </HEAD>
  9. <body text="#808080" link="#FF99CC" vlink="#FF8080" alink="#FF99CC" topmargin="0" leftmargin="0"><style>
  10. <!--
  11. BODY {SCROLLBAR-FACE-COLOR: #FFFFFF; SCROLLBAR-HIGHLIGHT-COLOR: #FFFFFF; SCROLLBAR-SHADOW-COLOR: #FFFFFF; SCROLLBAR-3DLIGHT-COLOR: #FFFFFF; SCROLLBAR-ARROW-COLOR:  #FFAAAA; SCROLLBAR-TRACK-COLOR: #FFFFFF; SCROLLBAR-DARKSHADOW-COLOR: #FFFFFF; }
  12. -->
  13. </style>
  14. <%
  15. String stu_id=ISOtoGb2312.convert(request.getParameter("stu_id"));
  16. String stu_password=ISOtoGb2312.convert(request.getParameter("stu_password"));
  17. Class.forName("sun.jdbc.odbc.JdbcOdbcDriver"); //载入驱动程序类别
  18. Connection con = DriverManager.getConnection("jdbc:odbc:dsn112"); //建立数据库链接
  19. Statement stmt = con.createStatement(ResultSet.TYPE_SCROLL_INSENSITIVE,
  20. ResultSet.CONCUR_READ_ONLY);
  21. String strsql;
  22. strsql="update Info set stu_password ='"stu_password"' where stu_id ='"stu_id"'";
  23. stmt.executeUpdate(strsql);
  24. %>
  25. <br><br><br><br>
  26.  <table  width="100%" cellspacing="0" cellpadding="4" rules="all" bordercolor="#CC9966" border="1" id="dg_rxkb" style="background-color:White;border-color:#CC9966;border-width:1px;border-style:None;width:99%;border-collapse:collapse;">
  27.   <tr>
  28.     <td align="center"><h3>你修改了的密码如下:</td>
  29.   </tr>
  30.  <tr>
  31.     <td>&nbsp;&nbsp;&nbsp;&nbsp;用户名:<%=stu_id%></td>
  32.   </tr>
  33.    <tr>
  34.     <td height="15"></td>
  35.   </tr>
  36.   <tr>
  37.     <td>&nbsp;&nbsp;&nbsp;&nbsp;密  码:<%=stu_password%></td>
  38.   </tr>
  39.   <tr><td height="15"></td></tr>
  40.   <tr>
  41.     <td  align="center">&nbsp;&nbsp;&nbsp;&nbsp;<a href="pwd.jsp">返回</a></td>
  42.   </tr>
  43.   <tr><td height="10"></td></tr>
  44. </table>
  45. <TABLE border="0" width="90%" align="center">
  46.        <tr>
  47.          <td height="10"></td>
  48.        </tr>
  49.        <tr>
  50.          <td align="center"></td>
  51.        </tr>
  52.        <tr>
  53.          <td height="10"></td>
  54.        </tr>
  55. </table>
  56. </BODY>
  57. </HTML>