I once had to do exactly the same thing.The problem is that if you first
send
a response that prins "Please Wait" then you can't just take it back and
send the actual response.You must first send the please wait page and the
very first thing
to do in this page is send a new resuest for the actual response (=a
redirect to the actual response page)
Two problems:
- You can't have an animated gif running on the please wait page.When
redirection begins the gif stops moving!
- If the user minimize and restore browser window, all page content will
seem blank.

The above way works, but it's not at all flexible.Perhaps javascript could
be an alternative.I suggest you do it the redirection way only if are in a
hurry.

The redirection code (here is merely a refresh ) will look like that:
<meta http-equiv="refresh" content="2; URL=getRecs">
inside the <head> f the html


----- Original Message -----
From: Alvin Chang
To: [EMAIL PROTECTED]
Sent: Thursday, March 06, 2003 10:21 PM
Subject: redirect a page



Hi,

I have a servlet which would take a while to generate the output and
I was wondering if someone would let me know how to
show a "please wait" on browser until the final output is complete.

code snippet would be great.

-Alvin Chang


--
http://www.freemail.gr - ������ �������� ������������ ������������.

___________________________________________________________________________
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

Reply via email to