Hi,
i am very new on J2EE and trying to learn servlets by following an example described in this link: Server-side Java: Understanding JavaServer Pages Model 2 architecture - JavaWorld
Unfortunately i am not able to make the example work, i am getting HTTP Status 404 error: The requested resource (/shopping/ShoppingServlet) is not available.
I am using Tomcat.
My directory structure is as follows:
WebContent/EShop.jsp
WebContent/Cart.jsp
WebContent/WEB-INF/classes/shopping/ShoppingServlet.class
WebContent/WEB-INF/classes/shopping/CD.class
WebContent/META-INF
And web.xml which is automatically created by eclipse is as follows :
<?xml version="1.0" encoding="UTF-8"?>
<web-app id="WebApp_ID" version="2.4" xmlns="http://java.sun.com/xml/ns/j2ee" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://java.sun.com/xml/ns/j2ee http://java.sun.com/xml/ns/j2ee/web-app_2_4.xsd">
<display-name>WebDev_2</display-name>
<servlet>
<description>
</description>
<display-name>ShoppingServlet</display-name>
<servlet-name>ShoppingServlet</servlet-name>
<servlet-class>
shopping.ShoppingServlet</servlet-class>
</servlet>
<servlet-mapping>
<servlet-name>ShoppingServlet</servlet-name>
<url-pattern>/ShoppingServlet</url-pattern>
</servlet-mapping>
<welcome-file-list>
<welcome-file>index.html</welcome-file>
<welcome-file>index.htm</welcome-file>
<welcome-file>index.jsp</welcome-file>
<welcome-file>default.html</welcome-file>
<welcome-file>default.htm</welcome-file>
<welcome-file>default.jsp</welcome-file>
</welcome-file-list>
</web-app>
What is the problem here?

