error.jsp revision 1364
369N/A<%--
369N/ACDDL HEADER START
369N/A
369N/AThe contents of this file are subject to the terms of the
369N/ACommon Development and Distribution License (the "License").
369N/AYou may not use this file except in compliance with the License.
369N/A
369N/ASee LICENSE.txt included in this distribution for the specific
369N/Alanguage governing permissions and limitations under the License.
369N/A
369N/AWhen distributing Covered Code, include this CDDL HEADER in each
369N/Afile and include the License file at LICENSE.txt.
369N/AIf applicable, add the following below this CDDL HEADER, with the
369N/Afields enclosed by brackets "[]" replaced with your own identifying
369N/Ainformation: Portions Copyright [yyyy] [name of copyright owner]
369N/A
369N/ACDDL HEADER END
369N/A
369N/ACopyright (c) 2005, 2010, Oracle and/or its affiliates. All rights reserved.
369N/APortions Copyright 2011 Jens Elkner.
5680N/A
5680N/A--%><%@ page session="false" isErrorPage="true" import="
5622N/Ajava.io.PrintWriter,
369N/Ajava.io.StringWriter,
5706N/A
5680N/Aorg.opensolaris.opengrok.web.Util"
369N/A%><%
369N/A/* ---------------------- error.jsp start --------------------- */
369N/A{
369N/A cfg = PageConfig.get(request);
844N/A cfg.setTitle("Error!");
844N/A
5622N/A String context = request.getContextPath();
369N/A String configError = "";
5680N/A if (cfg.getSourceRootPath().isEmpty()) {
369N/A configError = "CONFIGURATION parameter has not been configured in "
369N/A + "web.xml! Please configure your webapp.";
5002N/A } else if (!cfg.getEnv().getSourceRootFile().isDirectory()) {
369N/A configError = "The source root specified in your configuration does "
369N/A + "not point to a valid directory! Please configure your webapp.";
369N/A }
369N/A%><%@
369N/A
5706N/Ainclude file="httpheader.jspf"
5680N/A
369N/A%>
369N/A<body class="yui3-skin-sam">
369N/A<div id="page">
369N/A <div id="whole_header">
369N/A <div id="header">
369N/A<%@
369N/A
369N/Ainclude file="pageheader.jspf"
5002N/A
369N/A%>
369N/A </div>
369N/A <div id="Masthead"></div>
369N/A <div id="sbar"><%@
369N/A
include file="menu.jspf"
%></div>
</div>
<h3 class="error">There was an error!</h3>
<p class="error"><%= configError %></p><%
if (exception != null) {
%>
<p class="error"><%= exception.getMessage() %></p>
<pre><%
StringWriter wrt = new StringWriter();
PrintWriter prt = new PrintWriter(wrt);
exception.printStackTrace(prt);
prt.close();
out.write(Util.htmlize(wrt.toString()));
%></pre><%
} else {
%><p class="error">Unknown Error</p><%
}
}
/* ---------------------- error.jsp end --------------------- */
%><%@
include file="foot.jspf"
%>