Form in popup targets parent
popup window how can I submit a form, close the popup window and target the results of the form into the main window? Found at: http://www.irt.org
AI
Ringkasan AI: This codebase represents a historical implementation of the logic described in the metadata. Our preservation engine analyzes the structure to provide context for modern developers.
Kode Sumber
Use a timer to close the window, and add a TARGET to the form:
<FORM ACTION="apage.html" TARGET="mywindowname" onSubmit="setTimeout('window.close',2000)">
<INPUT TYPE="SUBMIT">
</FORM>
Now make sure that in the main window you set its name (by default the main window has no name):
<SCRIPT LANGUAGE="JavaScript"><!--
window.name="mywindowname"; // will not work in NN2 as name is read only
//--></SCRIPT>
Komentar Asli (3)
Dipulihkan dari Wayback Machine