Hi Yesudas and List,
I am not using Any sockets or connections to DB/File etc. Still, my
HttpServlet responds only the first time it's called from the browser
(IE5).
BTW, I am posting the actual code of my servlet. Hope that helps.
Thanks and regards,
- Ashish
import javax.servlet.*;
import javax.servlet.http.*;
import java.io.*;
public class ashServ extends HttpServlet{
public void doPost(HttpServletRequest myRequest,HttpServletResponse
myResponse) throws ServletException, IOException
{
myResponse.setContentType("text/html");
PrintWriter myOp = myResponse.getWriter();
myOp.println("<html><head><title>Servlet's
response</title></head>");
myOp.println("<body><p> Your Name is"
+myRequest.getParameter("username"));
myOp.println("</body></html>");
myOp.close();
}
}
----------
From: P.Yesudason[SMTP:[EMAIL PROTECTED]]
Reply To: A mailing list for discussion about Sun Microsystem's Java Se
rvlet API Technology.
Sent: Friday, March 24, 2000 8:11 PM
To: [EMAIL PROTECTED]
Subject: Re: Beginners' Blue........
Are you using any external connections like socket , file , Database etc
..Problem lies there ..
Let me know ..I will give you a hand
Yesudas
ASHISH VIJAY BORIKAR wrote:
> Hi Folks!
> I have been a member of this list for 2-3 days now..
> Just started off with Servlets, I have been facing this peculiar problem
> with my HttpServlet, which I am using for basic form
processing..(Printing
> User's name and age for starters.. - I have a html form for the same
> wherein I am Posting it with this Servlet's path in the Action attribute
> of the form tag ) It works Fine when I start the JavaServer.. but ONLY
> ONCE...
> The problem is : When I use the Same IE5 window,and refresh the form, and
> Submit Again, it gives me this DNS error. This happens always, except the
> first time. The only workable remedy could be to start another / new
> instance of IE(Not even a new window), and fill in the form and submit
all
> over again!!!
> Can anyBuddy help me in overcoming this ? (Can I, at the first place, run
> my servlet from the Same browser window for the second/third time; and if
> Yes, then How ??)
>
> Thanks a lot.
> Regards,
> - Ashish B
>
I am free and have a destination too far,
.... I will keep flying.
___________________________________________________________________________
To unsubscribe, send email to [EMAIL PROTECTED] and include in the body
of the message "signoff SERVLET-INTEREST".
Archives: http://archives.java.sun.com/archives/servlet-interest.html
Resources: http://java.sun.com/products/servlet/external-resources.html
LISTSERV Help: http://www.lsoft.com/manuals/user/user.html