src/main/webapp/WEB-INF/dynamic_fragments/error.jsp

changeset 72
0646c14e36fb
parent 55
1a3b998afba7
equal deleted inserted replaced
71:dca186d3911f 72:0646c14e36fb
29 <%@page import="de.uapcore.lightpit.modules.ErrorModule" %> 29 <%@page import="de.uapcore.lightpit.modules.ErrorModule" %>
30 <%@taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %> 30 <%@taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
31 <%@taglib prefix="fmt" uri="http://java.sun.com/jsp/jstl/fmt" %> 31 <%@taglib prefix="fmt" uri="http://java.sun.com/jsp/jstl/fmt" %>
32 <%@ taglib prefix="fn" uri="http://java.sun.com/jsp/jstl/functions" %> 32 <%@ taglib prefix="fn" uri="http://java.sun.com/jsp/jstl/functions" %>
33 33
34 <c:set scope="page" var="baseHref" value="${requestScope[Constants.REQ_ATTR_BASE_HREF]}" /> 34 <c:set scope="page" var="baseHref" value="${requestScope[Constants.REQ_ATTR_BASE_HREF]}"/>
35 <c:set scope="page" var="errorCode" value="${requestScope['javax.servlet.error.status_code']}"/> 35 <c:set scope="page" var="errorCode" value="${requestScope['javax.servlet.error.status_code']}"/>
36 <c:set scope="page" var="returnLink" value="${requestScope[ErrorModule.REQ_ATTR_RETURN_LINK]}"/> 36 <c:set scope="page" var="returnLink" value="${requestScope[ErrorModule.REQ_ATTR_RETURN_LINK]}"/>
37 37
38 <div id="error-page"> 38 <div id="error-page">
39 <h1><fmt:message key="h1"/></h1> 39 <h1><fmt:message key="h1"/></h1>
40 <table> 40 <table>
41 <tr> 41 <tr>
42 <th><fmt:message key="errorCode"/>:</th> 42 <th><fmt:message key="errorCode"/>:</th>
43 <td>${errorCode} - <fmt:message key="code.${errorCode}" /></td> 43 <td>${errorCode} - <fmt:message key="code.${errorCode}"/></td>
44 </tr> 44 </tr>
45 <tr> 45 <tr>
46 <th><fmt:message key="errorMessage" />:</th> 46 <th><fmt:message key="errorMessage"/>:</th>
47 <td><c:out value="${requestScope['javax.servlet.error.message']}"/></td> 47 <td><c:out value="${requestScope['javax.servlet.error.message']}"/></td>
48 </tr> 48 </tr>
49 <tr> 49 <tr>
50 <th><fmt:message key="errorTimestamp" />:</th> 50 <th><fmt:message key="errorTimestamp"/>:</th>
51 <td><fmt:formatDate type="both" value="<%= new java.util.Date()%>"/></td> 51 <td><fmt:formatDate type="both" value="<%= new java.util.Date()%>"/></td>
52 </tr> 52 </tr>
53 <%--@elvariable id="exception" type="java.lang.Exception"--%> 53 <%--@elvariable id="exception" type="java.lang.Exception"--%>
54 <c:if test="${not empty exception}"> 54 <c:if test="${not empty exception}">
55 <tr> 55 <tr>
56 <th><fmt:message key="errorExceptionText" />:</th> 56 <th><fmt:message key="errorExceptionText"/>:</th>
57 <td>${exception['class'].name} - ${exception.message}</td> 57 <td>${exception['class'].name} - ${exception.message}</td>
58 </tr> 58 </tr>
59 </c:if> 59 </c:if>
60 <c:if test="${fn:startsWith(returnLink, baseHref)}"> 60 <c:if test="${fn:startsWith(returnLink, baseHref)}">
61 <tr> 61 <tr>
62 <th><fmt:message key="errorReturnLink" />:</th> 62 <th><fmt:message key="errorReturnLink"/>:</th>
63 <td><a href="${returnLink}">${returnLink}</a></td> 63 <td><a href="${returnLink}">${returnLink}</a></td>
64 </tr> 64 </tr>
65 </c:if> 65 </c:if>
66 </table> 66 </table>
67 </div> 67 </div>

mercurial