Win a copy of Programmer's Guide to Java SE 8 Oracle Certified Associate (OCA) this week in the OCAJP forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

HFSJ page 171-177 problem

 
Nawar Gailani
Ranch Hand
Posts: 46
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi there,
I have an error in Tomcat while trying out this tutorial:


I rechecked everything, and all seem fine! So I started NetBeans (the holy gift) and copy'n'paste all the java sources. Everything just worked fine! I overwrote the classes in my Tomcat directory with the ones compiled from NetBeans, but still the error there! Can anyone help?
Here are the source files (although I don't think this is the problem!):








is there something wrong with my code?
Can I use NetBeans for this exam and skip all that headeache?!
Thanks in advance
[ October 25, 2006: Message edited by: Nawar Gailani ]
 
Christophe Verré
Sheriff
Posts: 14691
16
Eclipse IDE Ubuntu VI Editor
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Can you post your application's directory stucture, and the url you are trying to access. It seems you are trying to access something like http://localhost:8080/listenerTest/ListenTest.do. Is your application called listenerTest ?
Please confirm.
 
Nawar Gailani
Ranch Hand
Posts: 46
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi Satou,
The web.xml in:

And the three classes in:


The URL is:
http://localhost:8080/listenerTest/ListenTest.do

Hmmm! I think I found the 'silly' mistake! it is WEB-INF Nawar!!
Ok it is working now and I learned something: "Always prepare a strong coffee before you start coding!"

Thanks for your post Satou, and for this cup of coffee I'm drinking now!
 
Christophe Verré
Sheriff
Posts: 14691
16
Eclipse IDE Ubuntu VI Editor
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Glad you've found the problem
 
Patrick Gamble
Greenhorn
Posts: 2
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi

I am having the same error msg - can you expand on what you found wrong in your web.xml file

Thanks

Patrick
 
Patrick Gamble
Greenhorn
Posts: 2
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Sorry - disregard the last msg - realised what your problem was - not the file but the incorrect folder name. This wasn't my problem so I'm going to have to further re-examine it all

Thanks

Patrick
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic