tomcat中如何禁止列目录下的文件,404出错页
1. tomcat中如何禁止列目录下的文件
在{tomcat_home}/conf/web.xml中,把listings参数设置成false即可.
2.自定义404出错页
在WEB-INF/.xml文件的结尾添加如下:
<error-page>
<error-code> 404 </error-code>
<location> /index.jsp</location>
</error-page>
1. tomcat中如何禁止列目录下的文件
在{tomcat_home}/conf/web.xml中,把listings参数设置成false即可.
2.自定义404出错页
在WEB-INF/.xml文件的结尾添加如下:
<error-page>
<error-code> 404 </error-code>
<location> /index.jsp</location>
</error-page>
暂无评论。
评论功能维护中,当前仅展示历史评论。