欢迎您: 游客   等级: 游客 | 注册 | 登陆 |
发 贴
请选择需要发布主题的板块
用户名 密码
欢迎新会员: cofffee124  
   好空间网络,JSP空间,JSP虚拟主机论坛! » 深圳万网JSP虚拟主机,JSP空间区: » JSP空间售后服务中心 » 在web.xml中设置虚拟文件默认首页--index.do的方法
查看
46350
回复
17
zcdnsz
级别超级管理员
精华
积分1
财富0 jstruggle币
发帖数155
注册2009-8-21
状态 我暂时不在线
发表于2011-8-17 11:09 楼主
在web.xml中设置虚拟文件默认首页--index.do的方法

很多用户问我,怎么在后台设置默认主页为index.do的时候重启tomcat后不起作用呢??

附件26


现在把为什么不能设置index.do为主页,而设置其他页就正常的原因跟大家说下

使用Struts时,有时需要使用index.do获得数据后,再在首页index.jsp显示,这时需要将index.do设为首页。但是由于web.xml里面的默认页配置welcome-file 必须为物理存在的文件,那么对于index.do这样的首页,tomcat就不会继续往下处理,而直接返回404了。

    根据 Tomcat中用一段注释:

      When a request URI refers to a directory, the default servlet looks for a "welcome file" within that directory and, if present,  to the corresponding resource URI for display 。

      意思就是说,tomcat只要找到存在这样一个名字的物理文件,就会转到下面继续处理,那么简单了,在目录下建一个空的文件,名字就是index.do(小小的欺骗了一下tomcat),一切就搞定了!

 

附件27


简单吧`~~~随便建立个index.do的空文件放在跟目录下就可以了

另外如果还是没有生效,还要检查是不是自己已经手动在web.xml里设置过了默认访问页,因为我们的系统会默认如果用户自己设置了,就显示用户的配置,如果用户没有设置过才显示我们后台的配置,优先级没有用户自己配置的高,如果你已经手动配置过web.xml请删除你自己 的配置使我们的配置生效!

s s
http://www.8isp.cn 全国最大,最稳定,速度最快的JSP虚拟主机,JSP空间提供商!
分享  
20170808caihuali
级别新手上路
精华0
积分1
财富0 jstruggle币
发帖数0
注册2017-8-8
状态 我暂时不在线
发表于2017-8-8 09:21    1
20170808caihuali

ray-ban sunglasses

adidas outlet store

lebron james shoes

asics

marc jacobs outlet

ed hardy clothing

pandora jewelry

michael kors outlet

nike shoes

soccer shoes

cheap jordans

michael kors outlet

links of london

canada goose jackets

oakley sunglasses

mulberry outlet store

nike shoes

michael kors

true religion jeans

ugg boots

ugg outlet

nike air max

soccer jerseys

cheap jordans

longchamp bags

oakley sunglasses

ralph lauren uk

swarovski crystal

longchamp handbags

cheap nba jerseys

michael kors outlet

cheap oakley sunglasses

cheap ray bans

ray ban sunglasses

ray bans

oakley sunglasses

longchamp outlet

oakley sunglasses

michael kors outlet online

cheap jordans

kate spade outlet

tory burch outlet

pandora charms

ray ban sunglasses

christian louboutin outlet

coach outlet

canada goose jackets

oakley sunglasses

nba jerseys

michael kors outlet

ugg boots clearance,ugg boots,ugg boots outlet,ugg boots for women,ugg boots on sale,ugg boots for men,ugg boots for kids,ugg boots clearance sale women,ugg boots clearance outlet

michael kors outlet

polo outlet

michael kors factory outlet

michael kors outlet

fitflops shoes

true religion outlet

nike free 5

ugg boots

coach factory outlet

ugg boots

ralph lauren polo

birkenstock outlet

michael kors

cheap snapbacks

christian louboutin uk

coach outlet

longchamp bags

michael kors wallets

oakley sunglasses

uggs outlet

coach outlet online

ralph lauren outlet

ray ban sunglasses

ray ban sunglasses

nike huarache

ray ban sunglasses

nike huarache

longchamp outlet

Basketball Shoes

coach outlet store online

nike store

nike roshe one

oakley sunglasses

air max uk

oakley sunglasses

kate spade outlet

puma outlet

michael kors outlet

prada handbags

oakley sunglasses wholesale

tory burch outlet

nfl jerseys wholesale

true religion jeans

coach outlet online

basketball shoes

ugg outlet

ugg boots,ugg boots outlet,cheap uggs boots,ugg boots for women,ugg boots on sale,ugg boots clearance,ugg boots clearance sale women,ugg boots clearance outlet,ugg boots for men,ugg boots for kids

coach outlet

ugg outlet

chrome hearts

christian louboutin outlet

oakley sunglasses

polo shirts

ralph lauren polo

michael kors

canada goose outlet

ray ban sunglasses

michael kors outlet

pandora jewelry

oakley sunglasses

polo ralph lauren

nike trainers

cheap mlb jerseys

hermes outlet

kate spade handbags

Nike Free shoes

mcm outlet

canada goose outlet

michael kors handbags

mulberry handbags

canada goose jackets

air max 90

michael kors outlet

oakley sunglasses

michael kors outlet online

swarovski outlet

ferragamo shoes

polo outlet

fitflops shoes

nike roshe

ferragamo shoes

coach outlet

christian louboutin shoes

coach outlet online

nike air max

canada goose jackets

pandora outlet

bottega veneta outlet

nike air force 1

coach outlet

tory burch outlet

tory burch outlet

canada goose outlet

polo ralph lauren

hermes belt

longchamp handbags

adidas nmd runner

adidas uk

true religion jeans

fred perry polo shirts

oakley sunglasses

ugg outlet

fitflops sale clearance

coach outlet online

nfl jersey wholesale

vans shoes

ray ban sunglasses

true religion jeans

ugg outlet,ugg outlet sale,uggs outlet,ugg outlet online clearance,ugg outlet store,ugg outlet coupons,ugg outlet boots,ugg outlet online store

cheap nfl jerseys

ralph lauren pas cher

mbt shoes

canada goose outlet

ugg outlet,ugg outlet store,uggs outlet,ugg outlet online clearance,ugg outlet coupons,ugg outlet boots,ugg outlet online store,ugg outlet sale

michael kors outlet online

polo ralph lauren

nike foamposite

pandora jewelry

lacoste polo shirts

adidas shoes

michael kors handbags

mulberry sale

ray ban sunglasses

michael kors outlet

christian louboutin outlet

polo ralph lauren

hermes birkin

mulberry outlet

swarovski outlet

coach outlet online

ugg outlet

adidas outlet

mulberry bags

air max 90

coach outlet

ralph lauren polo

christian louboutin outlet

coach outlet

adidas shoes

pandora charms

montblanc pens

canada goose outlet

ralph lauren outlet

cartier outlet

ysl outlet

ugg boots,ugg boots outlet,ugg boots for women,ugg boots on sale,ugg boots clearance,ugg boots for men,ugg boots for kids,ugg boots clearance sale women,ugg boots clearance outlet

cheap jerseys wholesale

coach outlet online

cazal sunglasses

polo outlet

michael kors outlet

canada goose outlet

polo ralph lauren

michael kors outlet

michael kors outlet

kate spade outlet

air max 90

michael kors outlet clearance

christian louboutin outlet

air max 1

canada goose

burberry outlet

swarovski crystal

ray ban sunglasses

mac cosmetics

ugg boots for women,ugg boots,ugg boots outlet,ugg boots on sale,ugg boots clearance,ugg boots for men,ugg boots for kids,ugg boots clearance sale women,ugg boots clearance outlet

fitflops sale clearance

true religion outlet

ralph lauren sale

cheap nfl jerseys

ralph lauren uk

oakley sunglasses

coach outlet

ugg boots

cheap nhl jerseys

nike blazer pas cher

canada goose outlet

herve leger outlet

coach factory outlet

mulberry bags

oakley sunglasses

nike store uk

swarovski crystal

mbt shoes outlet

pandora jewelry

yeezy boost 350

true religion jeans

chrome hearts outlet

michael kors outlet

coach outlet

lacoste soldes

michael kors outlet

new balance shoes

adidas trainers

coach factory outlet

coach outlet

ray ban sunglasses

uggs outlet

ugg outlet

ferragamo outlet

michael kors

nike roshe run

polo ralph lauren

coach outlet online

air jordan 4

fitflops outlet

nike air max

coach outlet online

ray ban sunglasses

polo outlet

pandora outlet

coach outlet canada

true religion jeans

ralph lauren polo

coach outlet online

oakley sunglasses

prada sunglasses

coach outlet clearance

football shirts

oakley sunglasses wholesale

los angeles lakers jerseys

coach factory outlet

ray ban sunglasses

ugg boots

oakley sunglasses

kobe bryant shoes

ugg outlet

swarovski crystal

cheap jordan shoes

tory burch outlet

ferragamo outlet

ugg boots

coach outlet

fitflops sale

ray bans

kevin durant shoes

prada outlet

air max 90

nfl jersey wholesale

michael kors outlet online

polo outlet

fitflops

cleveland cavaliers jersey

ray ban sunglasses

michael kors outlet

polo ralph lauren

ugg outlet,ugg outlet clearance,uggs outlet,ugg outlet online clearance,ugg outlet store,ugg outlet online store,ugg outlet sale,ugg outlet coupons,ugg outlet boots

ray ban sunglasses

cheap snapbacks

soccer jerseys

canada goose outlet

thomas sabo

oakley sunglasses

tory burch shoes

true religion jeans

coach outlet online

canada goose outlet

kate spade handbags

nike shoes

ferragamo outlet

air max uk

michael kors handbags

coach outlet online

michael kors

mbt shoes

ugg outlet clearance,ugg outlet online clearance,ugg outlet,uggs outlet,ugg outlet store,ugg outlet coupons,ugg outlet boots,ugg outlet online store,ugg outlet sale

jordan shoes

christian louboutin online

oakley sunglasses

ray ban sunglasses

longchamp outlet

ferragamo shoes

yeezy boost

oakley sunglasses

adidas nmd

nike trainers

polo ralph lauren

michael kors outlet clearance

michael kors handbags

michael kors outlet

michael kors handbags

oakley sunglasses wholesale

christian louboutin shoes

fitflops

mulberry handbags

futbol baratas

canada goose jackets

polo outlet

michael kors handbags

reebok outlet store

coach handbags

ecco shoes

reebok trainers

hermes bags

nike outlet store

salomon shoes

mulberry handbags

christian louboutin outlet

mulberry handbags

adidas shoes

burberry outlet

michael kors outlet

cheap uggs outlet,cheap uggs for sale,cheap ugg boots,cheap uggs for kids,cheap uggs for women,cheap uggs bailey bow,cheap uggs china,cheap uggs for men,cheap uggs for girls,cheap uggs boots for women

cheap jordans

burberry outlet

ralph lauren polo shirts

converse shoes

ugg outlet

kobe shoes

nike air max 2015

true religion jeans

true religion outlet

coach outlet

fitflops sale clearance

mlb jerseys wholesale

true religion jeans

burberry outlet

tods outlet

jordan shoes

birkenstock sandals

supra shoes

mont blanc pens

cheap jordans

coach factory outlet

ferragamo shoes

longchamp handbags

jordan shoes

oakley sunglasses

prada shoes

nike outlet store

coach outlet

adidas wings

lebron james shoes

canada goose outlet

nike air max

michael kors bags

valentino outlet

michael kors handbags

nike outlet

canada goose outlet

nike shoes

true religion jeans

ugg outlet,uggs outlet,ugg outlet online clearance,ugg outlet store,ugg outlet coupons,ugg outlet boots,ugg outlet online store,ugg outlet sale

kobe 9

ugg outlet

true religion uk

coach outlet online

giuseppe zanotti outlet

ralph lauren polo

20170808caihuali
3w34ttt