There is a typo in the below. This > tomcat/server/webapps/billing/WEB-INF/web.xml
Should have been tomcat/server/webapps/foo/WEB-INF/web.xml So thats not the problem. Dan On Dec 14, 2007 3:10 PM, Dan Armbrust <[EMAIL PROTECTED]> wrote: > I want to create a webapp that just lists the content of a directory - > but I don't want to turn on directory listing globally. > > I've seen lots of people say it can be done, just do .... but I've yet > to find a working example. Can someone tell me what I'm missing here? > > I have a file: > > tomcat/conf/Catalina/localhost/foo.xml > > The contents are: > > <Context path="/foo" docBase="/dir/foo" debug="0" privileged="false"> > > </Context> > > > Now this, all by itself works for creating the webapp, and it will get > a directory listing if I enable global directory listing in the > web.xml file, but I don't want that. > > So, I created: > > tomcat/server/webapps/billing/WEB-INF/web.xml > > The contents are: > > <?xml version="1.0" encoding="UTF-8"?> > <!DOCTYPE web-app PUBLIC "-//Sun Microsystems, Inc.//DTD Web > Application 2.3//EN" "http://java.sun.com/dtd/web-app_2_3.dtd"> > <web-app> > <servlet> > <servlet-name>foo</servlet-name> > > <servlet-class>org.apache.catalina.servlets.DefaultServlet</servlet-class> > <init-param> > <param-name>debug</param-name> > <param-value>0</param-value> > </init-param> > <init-param> > <param-name>listings</param-name> > <param-value>true</param-value> > </init-param> > <load-on-startup>1</load-on-startup> > </servlet> > > <servlet-mapping> > <servlet-name>foo</servlet-name> > <url-pattern>/foo/*</url-pattern> > </servlet-mapping> > > </web-app> > > > But this doesn't work. > > What do I need to do to make this happen? > > Thanks, > > Dan > --------------------------------------------------------------------- To start a new topic, e-mail: users@tomcat.apache.org To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]