- Arawn's Dev Blog
- Outsider's Dev Story
- Toby's Epril
- Benelog
- NHN 개발자 블로그
- SK 플래닛 기술 블로그
- OLC CENTER
- 소프트웨어 경영/공학 블로그
- 모바일 컨버전스
- KOSR - Korea Operating System …
- 넥스트리 블로그
- 리버스코어 ReverseCore
- SLiPP
- 개발자를 위하여... (Nextree 임병인 수석)
- "트위터 부트스트랩: 디자이너도 놀라워할 매끈하고 직관…
- Learning English - The English…
- real-english.com
- 'DataScience/Deep Learning' 카테…
- Deep Learning Summer School, M…
- Deep Learning Courses
민서네집
How to specify the default error page in web.xml? 본문
web.xml 에서 다음과 같이 되어 있을때
<?xml version="1.0" encoding="UTF-8"?>
<web-app xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://java.sun.com/xml/ns/javaee" xmlns:web="http://java.sun.com/xml/ns/javaee/web-app_2_5.xsd" xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/web-app_2_5.xsd" id="WebApp_ID" version="2.5">
<error-page>
<error-code>403</error-code>
<location>/WEB-INF/views/exception/common/no_authority.html</location>
</error-page>
<error-page>
<error-code>404</error-code>
<location>/WEB-INF/views/exception/page_not_found.html</location>
</error-page>
<error-page>
<location>/WEB-INF/views/exception/uncaught_exception.html</location>
</error-page>
</web-app>
다음과 같은 이클립스 에러가 나면...
Description Resource Path Location Type
cvc-complex-type.2.4.a: Invalid content was found starting with element 'location'. One of '{"http://java.sun.com/xml/ns/javaee":error-code, "http://java.sun.com/xml/ns/javaee":exception-type}' is expected. web.xml /m2matm/src/webapp/WEB-INF line 123 XML Problem
< How to specify the default error page in web.xml? >
http://stackoverflow.com/questions/7066192/how-to-specify-the-default-error-page-in-web-xml
<?xml version="1.0" encoding="UTF-8"?>
<web-app xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://java.sun.com/xml/ns/javaee" xmlns:web="http://java.sun.com/xml/ns/javaee/web-app_3_0.xsd" xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/web-app_3_0.xsd" id="WebApp_ID" version="3.0">
xsd 를 2.5 에서 3.0 으로 수정하면 validation 에서 에러가 안난다.
'WEB (HTML, CSS)' 카테고리의 다른 글
jQuery Multiple File Upload with Progress bar (1) | 2013.11.05 |
---|---|
[css] 양쪽 정렬 버튼 (0) | 2013.10.17 |
input type="file" 에서 찾아보기 버튼 바꾸기 (0) | 2013.09.10 |
콤보박스(select)에서 Readonly (2) | 2013.09.03 |
eclipse aptana plugin 설치 (0) | 2013.08.07 |