Hello, This is probably quite a simple question but I couldn't find an answer in the archives:
I'm writing a servlet to perform a little search on my website. The servlet is compiled and is in a directory structure like this: $CATALINA_HOME/webapps/StudioSearch +-- index.html (provides a form to do a test search) +-- WEB-INF/ +-- web.xml (see below) +-- classes/ +-- uk/ +-- ac/ +-- uea/ +-- studios/ +-- StudioSearch.class +-- StudioSearch.java web.xml looks like this: <web-app> <servlet> <servlet-name>StudioSearch</servlet-name> <servlet-class>uk.ac.uea.studios.StudioSearch</servlet-class> </servlet> <servlet-mapping> <servlet-name>StudioSearch</servlet-name> <url-pattern>/studio-search</url-pattern> </servlet-mapping> </web-app> When I visit: http://localhost:8080/StudioSearch/ I get the index page as expected. This page has a <form> element where the action is "studio-search" but when I submit this form I get the following error: javax.servlet.ServletException: Error allocating a servlet instance ...... java.lang.NoClassDefFoundError: uk/ac/uea/studios/StudioSearch (wrong name: StudioSearch) at java.lang.ClassLoader.defineClass0(Native Method) at java.lang.ClassLoader.defineClass(ClassLoader.java:539) I've checked all the spelling and case and that I'm not using '.class' (the StudioSearch.java file isn't confusing it, is it?) but I can't seem to make it work. (I know the servlet class itself works because I've executed it Tomcat's ROOT webapp.) Any ideas? Thanks, Richard -- Richard Lewis [EMAIL PROTECTED] --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]