简单的办法就是把apache和tomcat的目录设为一致...apache配置是conf下的httpd.conf,修改
DocumentRoot "c:/tomcat/webapps/union"
<Directory "c:/tomcat/webapps/union">
tomcat配置是conf下的server.xml,修改
<Context path="" docBase="c:\tomcat\webapps\union"   
                   debug="0" reloadable="true">

解决方案 »

  1.   

    请关注
    http://www.csdn.net/expert/topic/1029/1029550.xml?temp=.168606
      

  2.   

    but i couldn't find the file of    httpd.conf :<<<
    my tomcat version is 4....          what about yours????
    do you mind telling me another solution?>
      

  3.   

    都说httpd.conf 是apache的了,tomcat里当然没有
      

  4.   

    7(Nomad) (  )
    说的是对的
      

  5.   

    tomcat和apache不是一个吗?
    apache又是什么冬冬
      

  6.   

    同意7(Nomad)的说法, 简单的办法就是把apache和tomcat的目录设为一致。但我不知道servlet的相关目录如何设?servlet的.class文件放置在何处?
      

  7.   

    还有一个问题,我设置了一个新的目录(E:\WEB),我把apache和tomcat的根目录全部指向他,已能正常浏览目录下的HTML和JSP,是不是一定要把apache和tomcat指向的根目录要一致?
      

  8.   

    servlet的class放到
    e:\web\WEB-INF\classes\中,如果你的web目录中没有这个目录,就自己创建而且,把e:\web\WEB-INF\classes\放到classpath中,这样jvm才能找到你调用的class