web项目使用配置web.xml实现重定向
2017-02-09 16:09
363 查看
1.实现方式
使用servlet和servlet-mapping实现重定向
参考资料:
https://docs.oracle.com/cd/E13222_01/wls/docs81/webapp/web_xml.html#1039287
使用servlet和servlet-mapping实现重定向
<!-- vip登录页面做特殊处理 --> <servlet> <servlet-name>vipLoginPath</servlet-name> <jsp-file>/vip/vipLogin.html</jsp-file> <!-- jsp-file和servlet-class只能同时使用其中一个--> </servlet> <servlet-mapping> <servlet-name>vipLoginPath</servlet-name> <url-pattern>/vip</url-pattern> </servlet-mapping>
参考资料:
https://docs.oracle.com/cd/E13222_01/wls/docs81/webapp/web_xml.html#1039287
相关文章推荐
- 项目中使用Spring时配置web.xml的listener侦听接口不能初始化的问题
- 一个基于servlet 3.0的不使用web.xml配置文件的建议web项目demo
- [Jersey]使用jersey实现RESTful web service 之 web.xml配置问题
- 使用JavaEE的ServerAuthModule模块和web.xml进行相应配置,实现对用户的权限控制
- 使用JavaEE的ServerAuthModule模块和web.xml进行相应配置,实现对用户的权限控制
- JAVA_WEB项目之使用Spring的xml配置方式在项目中管理Lucene检索框架
- Web项目中使用XML配置加载Spring及Spring MVC的组件
- servlet 3.0无需配置web.xml,使用注入方式配置servlet实现登陆功能(服务器需要支持servlet3.0)
- weblogic 9.2 配置使用及web项目部署
- Struts+Spring+Hibernate实现上传下载(spring的最低框架配置,web.xml等)
- WEB项目中,让FineReport6.5使用Tomcat下所配置的JNDI数据源
- 在 web.xml中配置error-page(错误重定向)
- ThreadLocal的实现原理,及使用实例,解决spring,hibernate非web项目下的懒加载 no session or session was closed(1)!
- Struts 项目中web.xml文件配置
- J2EE WEB项目web.xml标签使用方法
- Linux平台,使用JavaComm3 API及SMSLib项目实现在Web Application中发送手机短信的功能
- Asp.net中Web项目使用EnterpriseLibrary5.0独立配置文件找不到问题
- Struts 项目中web.xml文件配置
- web 项目中 在spring中使用log4j 定时刷新log4j配置文件
- ThreadLocal的实现原理,及使用实例,解决spring,hibernate非web项目下的懒加载 no session or session was closed(2)!