Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Reload parent without popup in IE 1

Status
Not open for further replies.

TKaeser

Technical User
Mar 4, 2002
16
CH
Hello,

Database frontend.

To do some data manipulation, I open a child window.

When done i'd like to reload the parent window to show the altered data.

Code:
<input type='submit' name='close' value='ok' onClick=&quot;window.opener.location.reload(); window.close;&quot;>

works ok, but IE prompts me every time to resend the form data in order to reload the page.

Is there a way to disable these prompts?
(don't ask, just send!)

Thank you!
Thomas
 
Hiya,

just an idea...

I think IE prompts you because you close the window before the (form) values are actually processed.

Better put that window.close in the onload of the page that does the processing.

Hope this does the trick! :p

Gtz,

Kristof
 
Thanks, Kristof

I'm sorry, I think I didn't describe the problem too well..

Retry:

Parent page contains a data table (from a DB query) and a form with some buttons.

To edit the data an icon is displayed in the data table:

Code:
<img src='graphics/edit.gif' onClick=&quot;javascript: window.open ('edit.php?maschid=$row[masch_id]','','');&quot;>

onClick then opens a child window:

edit.php contains a form where data is entered.
the form is submitted to edit.php again with a flag, which tells it to enter the altered data into the database.

after the insert has taken place, a confirm-message is displayed in the child window, along with a button to close it and to reload the parent page:

Code:
$js=&quot;javascript: window.opener.location.reload(); window.close ();&quot;;
echo &quot;<input type='submit' name='close' value='ok' onClick=\&quot;$js\&quot;>&quot;;

Here the annoying prompt pops up!

&quot; the page cannot be refreshed without resending the information [resend] [cancel] &quot;

Thank you for any hints!
Thomas
 
I have noticed this too and it's quite annoying. Seems to be only IE that does this. I doubt there's any way to eliminate the popup :-(
 
if you use &quot;get&quot; in the parent window's form i don't think it would give you the popup. cause the browser wouldn't need to re-post the data since you passed it with the querystring. [pipe]
 
Thank you, Discord!

That's it!
No more popups.

Thomas


 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top