为了账号安全,请及时绑定邮箱和手机立即绑定

为什么http://localhost:8080/myhome/在不设定欢迎页面的时候,index.jsp就能访问,改个名字就不能了?

为什么http://localhost:8080/myhome/在不设定欢迎页面的时候,index.jsp就能访问,改个名字就不能了?

正在回答

5 回答

未做配置时,index.jsp为默认首页,改名后就不能找到,其他名需要配置web.xml

0 回复 有任何疑惑可以回复我~

web.xml

0 回复 有任何疑惑可以回复我~

<welcome-file-list>

        <welcome-file>index.html</welcome-file>

        <welcome-file>index.htm</welcome-file>

        <welcome-file>index.jsp</welcome-file>

    </welcome-file-list>


0 回复 有任何疑惑可以回复我~

xml配置

0 回复 有任何疑惑可以回复我~

或者说哪个文件里的哪个代码把index.jsp设定为默认欢迎页面?

0 回复 有任何疑惑可以回复我~

举报

0/150
提交
取消

为什么http://localhost:8080/myhome/在不设定欢迎页面的时候,index.jsp就能访问,改个名字就不能了?

我要回答 关注问题
微信客服

购课补贴
联系客服咨询优惠详情

帮助反馈 APP下载

慕课网APP
您的移动学习伙伴

公众号

扫描二维码
关注慕课网微信公众号