PsychoSpunk has asked for the wisdom of the Perl Monks concerning the following question:
I've got a form that grabs focus in a text input field. When you submit the form it saves the info in the database and it returns to the same page that you come from. New complications have come up so that I have to pop-up a window to do extra tasks in specific cases. So I want to keep from giving the focus back to the text input field when it reloads the form in the main window. I have added: onload="self.focus();" into the new window, but that only avoids the problem temporarily by creating a race condition that is favorable to the new window getting focus. But what happens if the other script takes longer to reload the main window and grabs focus after the new one? That's why I want to add code to the main window in the event that a new window exists.
Oh yeah, the form must be submitted in order to have proper values available to the new window. Otherwise, I'd just hold off on executing the form until I had done what I needed in the new window.
ALL HAIL BRAK!!!
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re (tilly) 1: OT:A javascript problem.
by tilly (Archbishop) on Oct 04, 2000 at 20:17 UTC | |
|
RE: OT:A javascript problem.
by Anonymous Monk on Oct 05, 2000 at 11:07 UTC | |
by t0mas (Priest) on Oct 05, 2000 at 11:10 UTC |