Connecting Tech Pros Worldwide Forums | Help | Site Map

Reload after sumit

Marshall Dudley
Guest
 
Posts: n/a
#1: Jul 20 '05
I need to be able to allow a user to submit a form which opens another
window. This part I have working. But after the submit, I need to delay
and have the original window do a reload. I cannot figure out how to do
this. If I do a delay and reload with an OnSubmit, then the new window
will load only after the reload, which will not work.

Basically the first page displays a set of things that need to be done,
and after clicking on the button of something outstanding, a new window
pops up, and the action is preformed. Once the action is done, that
item is no longer needed to be done, so the original window I need to do
a reload, so it will not show up as outstanding any more. A 1 or 2
second delay would be plenty.

Any ideas?

Thanks,

Marshall


ExGuardianReader
Guest
 
Posts: n/a
#2: Jul 20 '05

re: Reload after sumit


Marshall Dudley wrote:
[color=blue]
> I need to be able to allow a user to submit a form which opens another
> window. This part I have working. But after the submit, I need to delay
> and have the original window do a reload. I cannot figure out how to do
> this. If I do a delay and reload with an OnSubmit, then the new window
> will load only after the reload, which will not work.
>
> Basically the first page displays a set of things that need to be done,
> and after clicking on the button of something outstanding, a new window
> pops up, and the action is preformed. Once the action is done, that
> item is no longer needed to be done, so the original window I need to do
> a reload, so it will not show up as outstanding any more. A 1 or 2
> second delay would be plenty.[/color]

Why have this second window?

If the main page needs to be reloaded anyway, just submit without a
target window specified, and have the servlet process the submission,
and return the new, updated page.

If you INSIST, then you can have the newly opened window calling a
javascript function in its parent window which does a reload. Use
window.opener to get to the parent. Or the child could call a Javascript
function in its parent window which just uses DOM calls to change the
display to remove the "outstanding" status.

There is no sleep() function in Javascript.

Closed Thread


Similar JavaScript / Ajax / DHTML bytes