web.xml ให้เพิ่มต่อไปนี้ลงไป
...
...
...
<!-- error page -->
<error-page>
<error-code>404</error-code>
<location>/error/404.xhtml</location>
</error-page>
<error-page>
<error-code>403</error-code>
<location>/error/403.xhtml</location>
</error-page>
<!-- error page -->
...
...
...
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE html>
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<title>Access is denied</title>
</head>
<body>
<h1>ไม่มีสิทธิ์เข้าถึง</h1>
</body>
</html>


ไม่มีความคิดเห็น:
แสดงความคิดเห็น