Hi guys,
I need some help with a method that will push a refresh to browser once
my server finishes processing.
This should happen regardless of a users action on the browser. I just
don't know where to look.
Please help.
Thanks
kana
Arne Vajhøj - 15 Oct 2006 03:36 GMT
> I need some help with a method that will push a refresh to browser once
> my server finishes processing.
> This should happen regardless of a users action on the browser. I just
> don't know where to look.
Output some JavaScript or HTML META tag that does it.
Obviously it can not be done entirely server side.
Arne
Manish Pandit - 15 Oct 2006 03:41 GMT
If you are using struts, that is how it would normally work. Your
action needs return the next URL to go to - which you can keep the same
as the page that invoked the action.
If you are not using struts or some sort of an MVC solution, the server
side cannot refresh the browser.
-cheers,
Manish
Simon Brooke - 15 Oct 2006 08:43 GMT
> I need some help with a method that will push a refresh to browser once
> my server finishes processing.
> This should happen regardless of a users action on the browser. I just
> don't know where to look.
That's because it is deliberately impossible; it's part of the core design
of the WWW that you can't do that. The user controls the browser, you
don't. You can only make suggestions.
However, with most modern browsers in their default setting, the following
will work:
Output a 'please wait' page to the browser when you start processing, with
the following in it's HEAD:
<meta http-equiv="Refresh"
content="0; URL=finishedprocessingurl">
Where 'finishedprocessingurl' is some URL to which your application will
only respond when it has finished processing.

Signature
simon@jasmine.org.uk (Simon Brooke) http://www.jasmine.org.uk/~simon/
;; Quidquid latine dictum sit, altum sonatur.