I have installed jdk and Tomcat version 1.5 and have created Simple Servlet Program .Inside Tomcat folder there is a webapps folder and inside webapps folder there is a root folder inside which I have created WEB-INF folder and inside WEB-INF I have again created one more folder which is classes folder.Inside the classes folder i have placed my Helloworld.java program.
I have set the following variables;
JAVA_HOME=d:\jdk
TOMCAT_HOME=d:\jakarta-tomcat5
path=d:\jdk\bin;
classpath=d;\jakarta-tomcat5\coomon\lib\servlet-api.jar;
Now I compile the program using the following command:
javac -classpath d:\jakarta-tomcat-5\common\lib\servlet-api.jar HelloWorld.java
Now after Compiling the HelloWorld.java program I start the Tomcat Server by doubleclicking the startup.bat file.
The command prompt appears for a while and then dissappears.
Now when I start the Browser and type the following URL:
http://localhost:8080/servlet/HelloWorld
it gives an error saying the page cannot be displayed.
(Note:Inside d drive I have created a folder named servlet and stored my HelloWorld program there.)
I have also created web.xml file and saved it inside WEB-INF folder.
Can u plz tell me why it is giving this error?