This week's book giveaway is in the Cloud/Virtualizaton forum.
We're giving away four copies of Mesos in Action and have Roger Ignazio on-line!
See this thread for details.
Win a copy of Mesos in Action this week in the Cloud/Virtualizaton forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Please help, servlets are not working

 
Tamer Ibrahim
Greenhorn
Posts: 4
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I just started working with servlets today, I tried the first example at "chapter 1" at Hanumant Deshmukh's book (SCWCD Exam Study Kit), I made everything as discribed in the book, but it keeps giving me an error of "resource not found".
I use TomCat 4.1 as suggested by the book auther.
 
Manoj Gundawar
Ranch Hand
Posts: 169
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi Tamer,
Things to be looked very carefully:

In Web.xml:
Servlet tag is correct. (class name etc)
Servlet mapping tag is given correctly.

Also make sure that servlet class is present in the correct directory under web-inf. Check the URL you are using to access the servlet.
Restart the server, after you do any corrections.
It should work. There is no magic in that, unless there is some silly error.
[ October 08, 2004: Message edited by: Manoj Gundawar ]
 
William Brogden
Author and all-around good cowpoke
Rancher
Posts: 13061
6
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Some books still use examples that require the "invoker" servlet. If the url you are using has "/servlet/" in it, that is where your problem probably lies. Read the Ranch FAQ on the Invoker.
Bill
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic