📄 getcourse_0002ejsp_jsp.java
字号:
import java.sql.*;
import javax.servlet.*;
import javax.servlet.http.*;
import javax.servlet.jsp.*;
import org.apache.jasper.runtime.*;
public class getcourse_0002ejsp_jsp extends HttpJspBase {
// begin [file="/getcourse.jsp";from=(6,0);to=(6,54)]
// end
static {
}
public getcourse_0002ejsp_jsp( ) {
}
private static boolean _jspx_inited = false;
public final void _jspx_init() throws org.apache.jasper.runtime.JspException {
}
public void _jspService(HttpServletRequest request, HttpServletResponse response)
throws java.io.IOException, ServletException {
JspFactory _jspxFactory = null;
PageContext pageContext = null;
HttpSession session = null;
ServletContext application = null;
ServletConfig config = null;
JspWriter out = null;
Object page = this;
String _value = null;
try {
if (_jspx_inited == false) {
synchronized (this) {
if (_jspx_inited == false) {
_jspx_init();
_jspx_inited = true;
}
}
}
_jspxFactory = JspFactory.getDefaultFactory();
response.setContentType("text/html; charset=gb2312");
pageContext = _jspxFactory.getPageContext(this, request, response,
"errorpage.jsp", true, 8192, true);
application = pageContext.getServletContext();
config = pageContext.getServletConfig();
session = pageContext.getSession();
out = pageContext.getOut();
// HTML // begin [file="/getcourse.jsp";from=(0,113);to=(6,0)]
out.write("\r\n<html>\r\n<head>\r\n<meta http-equiv=\"Content-Type\" content=\"text/html; charset=gb2312\">\r\n<title>所有课程</title>\r\n</head>\r\n");
// end
// begin [file="/getcourse.jsp";from=(6,0);to=(6,54)]
course course = null;
boolean _jspx_specialcourse = false;
synchronized (pageContext) {
course= (course)
pageContext.getAttribute("course",PageContext.PAGE_SCOPE);
if ( course == null ) {
_jspx_specialcourse = true;
try {
course = (course) java.beans.Beans.instantiate(this.getClass().getClassLoader(), "course");
} catch (ClassNotFoundException exc) {
throw new InstantiationException(exc.getMessage());
} catch (Exception exc) {
throw new ServletException (" Cannot create bean of class "+"course", exc);
}
pageContext.setAttribute("course", course, PageContext.PAGE_SCOPE);
}
}
if(_jspx_specialcourse == true) {
// end
// begin [file="/getcourse.jsp";from=(6,0);to=(6,54)]
}
// end
// HTML // begin [file="/getcourse.jsp";from=(6,54);to=(10,0)]
out.write("\r\n<body bgcolor=\"#0099FF\" text=\"#FFFFFF\" link=\"#00FF00\">\r\n<div align=\"center\">\r\n <p>\r\n");
// end
// begin [file="/getcourse.jsp";from=(10,2);to=(13,0)]
String id="",name="",prepare="",dep="";
int mark=0;
// end
// HTML // begin [file="/getcourse.jsp";from=(13,2);to=(29,0)]
out.write("\r\n <font color=\"#00FF00\" size=\"+3\" face=\"方正舒体\">所有课程</font> </p>\r\n <p> </p>\r\n <p align=\"left\"><a href=\"Addcourse.jsp\"><font size=\"+1\" face=\"方正舒体\"><strong>新增课程</strong></font></a></p>\r\n</div>\r\n<div align=\"center\">\r\n <table width=\"75%\" border=\"1\">\r\n <tr> \r\n <td>课程号</td>\r\n <td>课程名</td>\r\n <td>学分</td>\r\n <td>预修课</td>\r\n <td>所在系</td>\r\n <td>删除</td>\r\n <td>更新</td>\r\n </tr>\r\n");
// end
// begin [file="/getcourse.jsp";from=(29,2);to=(38,0)]
ResultSet rs=course.getCourse();
while(rs.next()) {
id=rs.getString("id");
name=rs.getString("name");
mark=rs.getInt("mark");
prepare=rs.getString("prepare");
dep=rs.getString("dep");
// end
// HTML // begin [file="/getcourse.jsp";from=(38,2);to=(39,9)]
out.write("\t\r\n\t<tr><td>");
// end
// begin [file="/getcourse.jsp";from=(39,12);to=(39,14)]
out.print(id);
// end
// HTML // begin [file="/getcourse.jsp";from=(39,16);to=(39,25)]
out.write("</td><td>");
// end
// begin [file="/getcourse.jsp";from=(39,28);to=(39,32)]
out.print(name);
// end
// HTML // begin [file="/getcourse.jsp";from=(39,34);to=(39,43)]
out.write("</td><td>");
// end
// begin [file="/getcourse.jsp";from=(39,46);to=(39,50)]
out.print(mark);
// end
// HTML // begin [file="/getcourse.jsp";from=(39,52);to=(39,61)]
out.write("</td><td>");
// end
// begin [file="/getcourse.jsp";from=(39,64);to=(39,71)]
out.print(prepare);
// end
// HTML // begin [file="/getcourse.jsp";from=(39,73);to=(40,5)]
out.write("</td>\r\n\t<td>");
// end
// begin [file="/getcourse.jsp";from=(40,8);to=(40,11)]
out.print(dep);
// end
// HTML // begin [file="/getcourse.jsp";from=(40,13);to=(41,49)]
out.write("</td>\r\n <td><a href=\"CourseSvlt?action=delete&id=");
// end
// begin [file="/getcourse.jsp";from=(41,52);to=(41,54)]
out.print(id);
// end
// HTML // begin [file="/getcourse.jsp";from=(41,56);to=(42,32)]
out.write("\">删除</a></td>\r\n\t<td><a href=\"updatecour.jsp?id=");
// end
// begin [file="/getcourse.jsp";from=(42,35);to=(42,37)]
out.print(id);
// end
// HTML // begin [file="/getcourse.jsp";from=(42,39);to=(43,0)]
out.write(" \">更新</a></td></tr>\r\n");
// end
// begin [file="/getcourse.jsp";from=(43,2);to=(45,0)]
}
// end
// HTML // begin [file="/getcourse.jsp";from=(45,2);to=(54,0)]
out.write("\t\r\n\t\r\n </table>\r\n \r\n </div>\r\n\r\n<p align=\"left\"><a href=\"admin.jsp\"><<BackTo Admin</a></p>\r\n</body>\r\n</html>\r\n");
// end
} catch (Throwable t) {
if (out != null && out.getBufferSize() != 0)
out.clearBuffer();
if (pageContext != null) pageContext.handlePageException(t);
} finally {
if (_jspxFactory != null) _jspxFactory.releasePageContext(pageContext);
}
}
}
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -