File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
The moose likes Servlets and the fly likes problem in calling servlet Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login

Win a copy of REST with Spring (video course) this week in the Spring forum!
JavaRanch » Java Forums » Java » Servlets
Bookmark "problem in calling servlet" Watch "problem in calling servlet" New topic

problem in calling servlet

gaurav chhabra
Ranch Hand

Joined: Jul 24, 2004
Posts: 109
i am new to servlet and using JSDK2.0 with SUN APPLICATION SERVER.
i want to call the servlet from HTML page , i m writing

and when i m calling by running through browser then it is
giving the error number 404.

please help me.
William Brogden
Author and all-around good cowpoke

Joined: Mar 22, 2000
Posts: 13025
The use of a URL containing /servlet/ is what is causing you trouble. Read this FAQ on the invoker servlet.
Divij Mahajan

Joined: Jul 26, 2004
Posts: 8
Hey Gaurav

Can you post the part of your web.xml that contains the servlet and servlet-mapping elements. and also the path where you have your servlet stored.

Maybe one of these is the cause.

-Divij<br />---------------------------------<br />Weinberg's Law: If builders built buildings the way programmers wrote programs, then the first woodpecker that came along would destroy civilization.
Navin Ramineni

Joined: Jul 28, 2004
Posts: 3
Also check if your firstservlet.class is in WEB-INF\classes directory
I agree. Here's the link:
subject: problem in calling servlet
It's not a secret anymore!