N
Nara Bala
I am doing my first servlet based web application. That accepts a name
and email and upon clicking the submit button, invokes a servlet to
print a welcome message. The code was taken from a book - professional
JSP.
I created this application from my own directory space. I created the
required directory structure and created the build directory with
ant. I then installed the application in tomcat using ant again. Now
the index.html page is shown in the web browser. However upon clicking
the submit button, the page displays 404 error for the servlet. I have
played around with the web.xml a lot...
<?xml version="1.0" encoding="ISO-8859-1"?>
<!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>
<servlet>
<!-- Servlet alias -->
<servlet-name>Registration</servlet-name>
<!-- Fully qualified Servlet class -->
<servlet-class>GreetingServlet</servlet-class>
</servlet>
<servlet-mapping>
<servlet-name>Registration</servlet-name>
<url-pattern>/Registration</url-pattern>
</servlet-mapping>
</web-app>
Kindly tell me what i am missing........
thanks
Nara
and email and upon clicking the submit button, invokes a servlet to
print a welcome message. The code was taken from a book - professional
JSP.
I created this application from my own directory space. I created the
required directory structure and created the build directory with
ant. I then installed the application in tomcat using ant again. Now
the index.html page is shown in the web browser. However upon clicking
the submit button, the page displays 404 error for the servlet. I have
played around with the web.xml a lot...
<?xml version="1.0" encoding="ISO-8859-1"?>
<!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>
<servlet>
<!-- Servlet alias -->
<servlet-name>Registration</servlet-name>
<!-- Fully qualified Servlet class -->
<servlet-class>GreetingServlet</servlet-class>
</servlet>
<servlet-mapping>
<servlet-name>Registration</servlet-name>
<url-pattern>/Registration</url-pattern>
</servlet-mapping>
</web-app>
Kindly tell me what i am missing........
thanks
Nara