• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

servlet does not load

 
Greenhorn
Posts: 6
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
hi
i am a beginner in servlets .
i am facing a problem that when i type
http://localhost:8080/servlet/myservlet1 in the browser
i donot get the output

the servlet class file is in Tomacat4.1\webapps\Root\Web-inf\classes directory

though the examples given in the webapps\Root\examples run fine
and also the welcome runs fine with
http://localhost:8080/
madhur
 
Ranch Hand
Posts: 84
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Check your web.xml file that should be available in the root of web-inf. You'll need to look at servlet mappings to ensure that any requests made to "/servlet/myServlet1" are appropriately routed to the instance of your running servlet:

Hope this helps! See Sun's Servlet Spec for more information (war files).
Cory Wilkerson
 
Author and all-around good cowpoke
Posts: 13078
6
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
For Tomcat 4.1.1? they made a change in the defaults so that /servlet/yourservlet doesn't work. I recently found a nice tutorial on getting Tomcat 4.1?? working at Tutorial at Moreservlets.
See item 3 under Configure Tomcat which discusses the "invoker" servlet.
Bill
 
Mo-om! You're embarassing me! Can you just read a tiny ad like a normal person?
a bit of art, as a gift, the permaculture playing cards
https://gardener-gift.com
reply
    Bookmark Topic Watch Topic
  • New Topic