你试试把server.xml中的配置改一下。<Context path="d:\jstest"   

解决方案 »

  1.   

    server.xml里好象没有你说的这个啊!
    我用搜索了下,说没找到。
      

  2.   

    在tomcat的管理界面里面自己去配一个Context,指定路径。tomcat5.0.28是每个context一个xml文件配置,你在conf目录下继续往下就可以看到。
      

  3.   

    在conf里面有个server的文件
    在里面查找context找到这个东西
    <Context path="XXXXX" docBase="XXXXX" debug="0"
    自己把XXXX改成你想改的就行了
      

  4.   

    TOMCAT 5的话..在conf\Catalina\localhost里
    一个XML文件代到一个目录想设一个虚拟目录的话,就随便拷一个改改就是了...
    path为虚拟目录名
    docBase为物理目录名一楼说的是TOMCAT4的设法...
    <?xml version="1.0" encoding="gbk"?>
    <!--    Context configuration file for the Tomcat Administration Web App    $Id: admin.xml,v 1.3 2004/02/20 17:09:19 remm Exp $-->
    <Context path="/gree" docBase="E:\Java设计\gree2004-9-13\stockmodule">  <!-- Uncomment this Valve to limit access to the Admin app to localhost
       for obvious security reasons. Allow may be a comma-separated list of
       hosts (or even regular expressions).
      <Valve className="org.apache.catalina.valves.RemoteAddrValve"
        allow="127.0.0.1"/>
      -->
    </Context>