오류 및 예외 페이지 처리
This commit is contained in:
parent
42442f901a
commit
663f9a5276
@ -63,6 +63,7 @@ public class SpringSecurityConfig extends WebSecurityConfigurerAdapter {
|
||||
.antMatchers("/js/**")
|
||||
.antMatchers("/temp/**")
|
||||
.antMatchers("/favicon/**")
|
||||
.antMatchers("/html/**")
|
||||
;
|
||||
}
|
||||
|
||||
|
||||
@ -81,15 +81,15 @@
|
||||
|
||||
<error-page>
|
||||
<exception-type>java.lang.Throwable</exception-type>
|
||||
<location>/common/error.jsp</location>
|
||||
<location>/common/error-throw.jsp</location>
|
||||
</error-page>
|
||||
<error-page>
|
||||
<error-code>404</error-code>
|
||||
<location>/common/error.jsp</location>
|
||||
<location>/common/error404.jsp</location>
|
||||
</error-page>
|
||||
<error-page>
|
||||
<error-code>500</error-code>
|
||||
<location>/common/error.jsp</location>
|
||||
<location>/common/error500.jsp</location>
|
||||
</error-page>
|
||||
|
||||
</web-app>
|
||||
|
||||
24
src/main/webapp/common/error-throw.jsp
Normal file
24
src/main/webapp/common/error-throw.jsp
Normal file
@ -0,0 +1,24 @@
|
||||
<%@ page contentType="text/html; charset=utf-8" pageEncoding="utf-8"%>
|
||||
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core"%>
|
||||
<%@ taglib prefix="spring" uri="http://www.springframework.org/tags"%>
|
||||
<%
|
||||
String councilCd = (String)session.getAttribute("councilCd");
|
||||
String councilNm = (String)session.getAttribute("councilNm");
|
||||
%>
|
||||
|
||||
<div class="wrap">
|
||||
<div class="error">
|
||||
<div class="text">
|
||||
<p><span>500 ERROR :</span> Service Error</p>
|
||||
<p>죄송합니다. 현재 서비스가 원활하지 않습니다.</p>
|
||||
<p><img src="/images/icon/icon-error.png" alt="에러 아이콘"></p>
|
||||
</div>
|
||||
<div class="box">
|
||||
<p>서비스 이용에 불편을 드려 죄송합니다.<br>예상치못한 시스템 오류가 발생하였습니다.<br>시스템 관리자에게 문의해 주시거나 잠시 후 다시 시도해주세요.
|
||||
</p>
|
||||
<div class="btn">
|
||||
<a href="javascript:void(0)" onclick="javascript:window.location.reload();" class="btn-white">새로고침</a>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@ -1,33 +0,0 @@
|
||||
<%@ page contentType="text/html; charset=utf-8" pageEncoding="utf-8"%>
|
||||
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core"%>
|
||||
<%@ taglib prefix="spring" uri="http://www.springframework.org/tags"%>
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
||||
<html xmlns="http://www.w3.org/1999/xhtml" lang="ko" xml:lang="ko">
|
||||
<head>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
|
||||
<link rel="stylesheet" type="text/css" href="<c:url value='/css/egovframework/egov.css'/>" />
|
||||
<title>NLIB</title>
|
||||
</head>
|
||||
|
||||
<body>
|
||||
<table width="100%" height="100%" border="0" cellpadding="0" cellspacing="0">
|
||||
<tr>
|
||||
<td width="100%" height="100%" align="center" valign="middle" style="padding-top: 150px;"><table border="0" cellspacing="0" cellpadding="0">
|
||||
<tr>
|
||||
<td class="<spring:message code='image.errorBg' />">
|
||||
<span style="font-family: Tahoma; font-weight: bold; color: #000000; line-height: 150%; width: 440px; height: 70px;">Error</span>
|
||||
<br>
|
||||
status_code = <%=request.getAttribute("javax.servlet.error.status_code") %><br>
|
||||
exception_type = <%=request.getAttribute("javax.servlet.error.exception_type") %><br>
|
||||
message = <%=request.getAttribute("javax.servlet.error.message") %><br>
|
||||
request_uri = <%=request.getAttribute("javax.servlet.error.request_uri") %><br>
|
||||
exception = <%=request.getAttribute("javax.servlet.error.exception") %><br>
|
||||
servlet_name = <%=request.getAttribute("javax.servlet.error.servlet_name") %><br>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
</body>
|
||||
</html>
|
||||
44
src/main/webapp/common/error404.jsp
Normal file
44
src/main/webapp/common/error404.jsp
Normal file
@ -0,0 +1,44 @@
|
||||
<%@ page contentType="text/html; charset=utf-8" pageEncoding="utf-8"%>
|
||||
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core"%>
|
||||
<%@ taglib prefix="spring" uri="http://www.springframework.org/tags"%>
|
||||
<%
|
||||
String councilCd = (String)session.getAttribute("councilCd");
|
||||
String councilNm = (String)session.getAttribute("councilNm");
|
||||
%>
|
||||
<!DOCTYPE html>
|
||||
<html lang="ko">
|
||||
<head>
|
||||
<meta charset="utf-8">
|
||||
<meta http-equiv="X-UA-Compatible" content="IE=Edge">
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||||
<meta name="format-detection" content="telephone=no" />
|
||||
<title>소장자료관</title>
|
||||
<link href="/css/common.css" rel="stylesheet">
|
||||
<link href="/css/default.css" rel="stylesheet">
|
||||
<script src="/js/jquery-1.11.2.min.js"></script>
|
||||
<script src="/js/jquery.mCustomScrollbar.js"></script>
|
||||
<script src="/js/swiper.min.js"></script>
|
||||
<script src="/js/default.js"></script>
|
||||
</head>
|
||||
<body>
|
||||
|
||||
<div class="wrap">
|
||||
<div class="error">
|
||||
<div class="text">
|
||||
<h1><a href="javascript:void(0)" onclick="javascript:location.href='/';"><img src="/images/icon/icon-logo.png" alt="문화원로고"><span class="title"><%=councilNm %></span></a><span class="collection">소장자료관</span></h1>
|
||||
<p><span>404 ERROR :</span> Page not found</p>
|
||||
<p>죄송합니다. 요청하신 페이지를 찾을 수 없습니다.</p>
|
||||
<p><img src="/images/icon/icon-error.png" alt="에러 아이콘"></p>
|
||||
</div>
|
||||
<div class="box">
|
||||
<p>방문하시려고 하는 페이지의 주소가 잘못 입력되었거나,<br>페이지의 주소가 변경 또는 삭제되어 찾을 수 없습니다.</p>
|
||||
<div class="btn">
|
||||
<a href="javascript:void(0)" onclick="javascript:history.back(-1);" class="btn-white">이전페이지로</a>
|
||||
<a href="javascript:void(0)" onclick="/" class="btn-color">소장자료관으로</a>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</body>
|
||||
</html>
|
||||
44
src/main/webapp/common/error500.jsp
Normal file
44
src/main/webapp/common/error500.jsp
Normal file
@ -0,0 +1,44 @@
|
||||
<%@ page contentType="text/html; charset=utf-8" pageEncoding="utf-8"%>
|
||||
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core"%>
|
||||
<%@ taglib prefix="spring" uri="http://www.springframework.org/tags"%>
|
||||
<%
|
||||
String councilCd = (String)session.getAttribute("councilCd");
|
||||
String councilNm = (String)session.getAttribute("councilNm");
|
||||
%>
|
||||
<!DOCTYPE html>
|
||||
<html lang="ko">
|
||||
<head>
|
||||
<meta charset="utf-8">
|
||||
<meta http-equiv="X-UA-Compatible" content="IE=Edge">
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||||
<meta name="format-detection" content="telephone=no" />
|
||||
<title>소장자료관</title>
|
||||
<link href="/css/common.css" rel="stylesheet">
|
||||
<link href="/css/default.css" rel="stylesheet">
|
||||
<script src="/js/jquery-1.11.2.min.js"></script>
|
||||
<script src="/js/jquery.mCustomScrollbar.js"></script>
|
||||
<script src="/js/swiper.min.js"></script>
|
||||
<script src="/js/default.js"></script>
|
||||
</head>
|
||||
<body>
|
||||
|
||||
<div class="wrap">
|
||||
<div class="error">
|
||||
<div class="text">
|
||||
<h1><a href="javascript:void(0)" onclick="javascript:location.href='/';"><img src="/images/icon/icon-logo.png" alt="문화원로고"><span class="title"><%=councilNm %></span></a><span class="collection">소장자료관</span></h1>
|
||||
<p><span>500 ERROR :</span> Service Error</p>
|
||||
<p>죄송합니다. 현재 서비스가 원활하지 않습니다.</p>
|
||||
<p><img src="/images/icon/icon-error.png" alt="에러 아이콘"></p>
|
||||
</div>
|
||||
<div class="box">
|
||||
<p>서비스 이용에 불편을 드려 죄송합니다.<br>예상치못한 시스템 오류가 발생하였습니다.<br>시스템 관리자에게 문의해 주시거나 잠시 후 다시 시도해주세요.
|
||||
</p>
|
||||
<div class="btn">
|
||||
<a href="javascript:void(0)" onclick="javascript:window.location.reload();" class="btn-white">새로고침</a>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</body>
|
||||
</html>
|
||||
Loading…
Reference in New Issue
Block a user