V
vunet.us
Hello,
My web.xml works fine on Tomcat 4. But when I added new servlet (see
code below between comments), it stopped working. However, Tomcat 5
runs that new web.xml with these changes without any problems. So,
there is something with that new <servlet> addition that causes error.
Please, suggest. Thank you.
<!DOCTYPE web-app PUBLIC
"-//Sun Microsystems, Inc.//DTD Web Application 2.2//EN"
"http://java.sun.com/j2ee/dtds/web-app_2_2.dtd">
<web-app>
<!-- Added Below -->
<servlet>
<servlet-name>myServlet</servlet-name>
<servlet-class>direct.myServlet</servlet-class>
<load-on-startup>1</load-on-startup>
</servlet>
<servlet-mapping>
<servlet-name>myServlet</servlet-name>
<url-pattern>/servlet/direct.myServlet</url-pattern>
</servlet-mapping>
<!-- Added Above -->
</web-app>
My web.xml works fine on Tomcat 4. But when I added new servlet (see
code below between comments), it stopped working. However, Tomcat 5
runs that new web.xml with these changes without any problems. So,
there is something with that new <servlet> addition that causes error.
Please, suggest. Thank you.
<!DOCTYPE web-app PUBLIC
"-//Sun Microsystems, Inc.//DTD Web Application 2.2//EN"
"http://java.sun.com/j2ee/dtds/web-app_2_2.dtd">
<web-app>
<!-- Added Below -->
<servlet>
<servlet-name>myServlet</servlet-name>
<servlet-class>direct.myServlet</servlet-class>
<load-on-startup>1</load-on-startup>
</servlet>
<servlet-mapping>
<servlet-name>myServlet</servlet-name>
<url-pattern>/servlet/direct.myServlet</url-pattern>
</servlet-mapping>
<!-- Added Above -->
</web-app>