errorpage.jsp

来自「Java写的ERP系统」· JSP 代码 · 共 31 行

JSP
31
字号
<%@ page isErrorPage="true" %>
<html>
<head>
<title>Compiere Error</title>
</head>
<body>
<h1>Compiere Error</h1>
<p>Sorry, an error occured. If the error persists, please inform us.</p>
<p>Error Message:</p>
<pre><font color="red">
<%= exception.getMessage() %>
</font></pre>
<h2>Stack Trace:</h2>
<%
 	java.lang.Throwable ex = exception;
	while (ex != null)
	{
		out.println("<h3>" + ex.toString() + "</h3>");
		java.io.CharArrayWriter cw = new java.io.CharArrayWriter();
		java.io.PrintWriter pw = new java.io.PrintWriter(cw,true);
		ex.printStackTrace (pw);
		out.println("<pre><font color=\"red\">");
		out.println(cw.toString());
		out.println("</font></pre>");
		ex = exception.getCause();
	}
%>
<br>
</body>
</html>

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?