• Post Reply Bookmark Topic Watch Topic
  • New Topic

listener tag is not working in Tomcat

 
Sreeraj G Harilal
Ranch Hand
Posts: 310
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I create a ServletContext Listener class


then i add the listener tag in web.xml file


my problem is if i put listener tag in web.xml my web application is not starting.
ranchers, Please tell me what is the problem.
 
Christophe Verré
Sheriff
Posts: 14691
16
Eclipse IDE Ubuntu VI Editor
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
First, Try to remove the extra spaces


Then, put the listener into a package. You'll get unpredictable results by putting your classes in the default package.
[ November 17, 2006: Message edited by: Satou kurinosuke ]
 
Sreeraj G Harilal
Ranch Hand
Posts: 310
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Satou, still its not working.I removed the space but still not wrking.
Another thing is i am not working with default web application.i hve a directory named Manning under webapps.

Is it the problem of tomcat?
 
Sreeraj G Harilal
Ranch Hand
Posts: 310
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Sorry everyone.It was my fault. I forget to make that listener class public.
Sorry once again.
 
Happiness is not a goal ... it's a by-product of a life well lived - Eleanor Roosevelt. Tiny ad:
the new thread boost feature: great for the advertiser and smooth for the coderanch user
https://coderanch.com/t/674455/Thread-Boost-feature
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!