首页 新闻 会员 周边

【问题】在浏览器输入localhost:8080/admin,如何自动跳转?

0
悬赏园豆:30 [已解决问题] 解决于 2014-05-23 11:47

【问题】在浏览器输入localhost:8080/admin,如何自动跳转? 

1.前台:自动跳转(比如,输入 localhost:8080,然后跳转到 localhost:8080/index.jsp),是通过web.xml里配置的,如下: 
<welcome-file-list> 
        <welcome-file>index.html</welcome-file> 
        <welcome-file>index.htm</welcome-file> 
        <welcome-file>index.jsp</welcome-file> 


2.后台:自动跳转是如何跳转的呢?(比如,输入 localhost:8080/admin,然后跳转到 localhost:8080/admin/后台登陆首页) 

问题补充:

补充:配置文件web.xml里面,有一个过滤器,它拦截所有的*.jsp页面:

 

<filter>
<filter-name></filter-name>
<filter-class></filter-class>
</filter>

<filter-mapping>
<filter-name></filter-name>
<url-pattern>*.jsp</url-pattern>
</filter-mapping>

 

B_yellow的主页 B_yellow | 初学一级 | 园豆:5
提问于:2014-05-22 17:02
< >
分享
最佳答案
0

参考:http://www.iteye.com/problems/101520

B_yellow | 初学一级 |园豆:5 | 2014-05-23 11:47
其他回答(2)
0

你后台首页设置成index.html不就行了

收获园豆:15
TuWei | 园豆:129 (初学一级) | 2014-05-22 17:14
0

MVC的话是设置默认路由.

其它的是IIS里设置默认首页

收获园豆:15
吴瑞祥 | 园豆:29449 (高人七级) | 2014-05-22 17:54
清除回答草稿
   您需要登录以后才能回答,未注册用户请先注册