我的tomcat装在D:/下面,而我有一个项目是在d:/weboo/下面
我的web.xml文件里是这样的
<welcome-file-list>
<welcome-file>index.jsp</welcome-file>
<welcome-file>index.html</welcome-file>
<welcome-file>index.htm</welcome-file>
</welcome-file-list>
我的server.xml文件是这样设置的
<Context path="/nk" reloadable="true" docBase="D:\weboo\Ande" workDir="D:\weboo\Ande" />为什么我访问http://localhost:8301/nk/index.jsp的时候是tomcat的测试页面呢,而不是我项目的首页。
请问各位大哥,怎么解决啊!

解决方案 »

  1.   

    我有一个项目是在d:/weboo/下面D:\weboo\Ande
    为什么这里会多一级Ande?
      

  2.   

    哦,不好意思,地址写错了,项目应该在D:\weboo\Ande下面
      

  3.   

    不要访问http://localhost:8301/nk/index.jsp,
    直接访问http://localhost:8301/nk,
    会自动去web.xml中寻找welcome画面,
    index.jsp找不到,就找第二个index.html,第二个找不到,就找第三个。
    不过,首先你要确信,index.jsp是否在D:\weboo\Ande目录下。
      

  4.   

    index.jsp确定在我的d:\weboo\ande目录下,http://localhost:8301/nk/index.jsp和http://localhost:8301/nk都是一样的!都出现默认的测试页面