Win a copy of Clojure in Action this week in the Clojure forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

HTTP 404 error

 
shanthisri mocherla
Ranch Hand
Posts: 119
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
hello Friend
I'm getting this error when I 'm trying to exceute my form.html from the the browser .
I'm typing this in my browser.
http://localhost:8080/serv1/form.html

The error is HTTP status 404 -/serv/form.html.

The requested resource (/serv1/form.html) is not available.

Actually this code worked fine foe me when I tried it a month ago.But Strangely it is not working right now.??
I've been struggling with this code since yesterday.
serv1 is the directory under webapps directory.

Can anyone tell me what could be the problem???Is it something to do with the web.xml or classpath??
I dont think so.

Shanthi
 
Martyn Clark
Ranch Hand
Posts: 108
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi
Have you checked to make sure the app is loading if your running tomcat go to manager page and reload if it is not loading then the problem is your web.xml.
It would not be classpath seens as it is just an html page.
 
shanthisri mocherla
Ranch Hand
Posts: 119
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi Martyn
I'm gettig the form.html executed when I'm using http://localhost:8080/servlet-examples/form.html where in servlet-examples is the directory I got along with the TomCat .the path is

XXX/TomCat5.0/webapps/servlet-examples/form.html.
But when I'm trying to execute the form.html from the serv1 directory which I've created, it is not getting executed.
i dont know what's happening.

Thanks for your reply
Shanthi
 
Martyn Clark
Ranch Hand
Posts: 108
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi shanthisri
yes this will work because the servlet-examples will be loaded by default so you know that one is running. Have you checked with tomcat manerger to see which apps are loading when you start tomcat if you just go to localhost/ and click manager on to left side of page it will ask you to log in then you can tell if serv1 is running just to make sure if you clik reload on that page at the very top you will get a message in plain text to tell you if it loaded ok.
if not take another look at the web.xml file for that app, just a silly little spelling mistake will stop it from loading.
 
shanthisri mocherla
Ranch Hand
Posts: 119
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi Martyn

At last
my code started working.i think I had some typos in my web.xml.I checked each and every line in my web.xml.

As you suggested ,I'm trying to go to Manager page in tomcat, it is asking me to log in.I dont know what to type in username and password fields.
Thank you very much fro your help.

Shanthi
[ January 25, 2006: Message edited by: shanthisri mocherla ]
 
Christophe Verré
Sheriff
Pie
Posts: 14691
16
Eclipse IDE Ubuntu VI Editor
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
There is a file called tomcat-users.xml in the conf directory of Tomcat.
Check the name and password of the administrator.
 
It is sorta covered in the JavaRanch Style Guide.
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic