?? updatestudent.jsp
字號:
<%@ page contentType="text/html; charset=gb2312" language="java" import="java.sql.*" %>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
<title>無標題文檔</title>
</head>
<jsp:useBean id="update" scope="page" class="update">
<jsp:setProperty name="update" property="*"/>
</jsp:useBean>
<body bgcolor="#0099FF" text="#FFFFFF" link="#00FF00">
<%
try {
String s = request.getParameter("password");
if(s==null || s.equals("")) throw new Exception("錯誤,密碼不能為空!!");
String stu_id = (String)session.getAttribute("id");
if(stu_id==null){response.sendRedirect("login.jsp");}
update.setStu_id(stu_id);
update.update();
String d= update.getStu_id();
out.print("學生號: "+d+"<br>");
String a = update.getPassword();
out.print("您的新密碼: "+a+"<br>");
String b= update.getTel();
out.print("您的電話: "+b+"<br>");
String c= update.getE_mail();
out.print("E_mail: "+c+"<br>");
%>
<p><a href="student.jsp"><<您已經更新成功,請返回</a>
<p>
<%
}catch (Exception e){out.print(e.toString());}
%>
</body>
</html>
?? 快捷鍵說明
復制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號
Ctrl + =
減小字號
Ctrl + -