From net1_2004 at hotmail.com Tue Jun 1 00:44:03 2004 From: net1_2004 at hotmail.com (net 1) Date: Tue Jun 1 00:44:36 2004 Subject: [Java@ISI] servlet does not function with package Message-ID: I have the servlet Contatore.java with the following path: C:\Programmi\Apache Software Foundation\Tomcat 5.0\webapps\Contatore\WEB-INF\classes\contatore_01 I use winXp pro and Tomcat 5.0 Contatore.class is 1.60 KB. With NetBeans The url is http://localhost:8084/contatore/contatore_01/Contatore using tomcat withoput NetBean the url is http://localhost:8080/contatore/contatore_01/Contatore In both the 2 cases the same error when I execute the servlet I have the error from tomcat: HTTP Status 404 - /contatore/contatore_01/Contatore -------------------------------------------------------------------------------- type Status report message /contatore/contatore_01/Contatore description The requested resource (/contatore/contatore_01/Contatore) is not available. -------------------------------------------------------------------------------- Apache Tomcat/5.0.19 here the program Contatore,java package contatore_01; import java.io.*; import javax.servlet.*; import javax.servlet.http.*; public class Contatore extends HttpServlet { private int conta; public void init(ServletConfig config) throws ServletException { conta = 0; } public void doGet(HttpServletRequest richiesta, HttpServletResponse risposta) throws IOException, ServletException { conta++; risposta.setContentType("text/html"); PrintWriter out = risposta.getWriter(); out.println(""); out.println(""); out.println("Pagina con contatore"); out.println(""); out.println(""); out.println("Questa pagina e' stata visualizzata"); out.println("

"+conta+ "

volte."); out.println(""); out.println(""); out.close(); } } and here is web.xml Contatore Contatore Contatore /Contatore Can someone help me? Thanks Eugenia Mariani _________________________________________________________________ Personalizza MSN Messenger con sfondi e fotografie! http://www.ilovemessenger.msn.it/