html form/javascript help - Printable Version -Shoutbox (https://shoutbox.menthix.net) +-- Forum: MsgHelp Archive (/forumdisplay.php?fid=58) +--- Forum: Skype & Technology (/forumdisplay.php?fid=9) +---- Forum: Tech Talk (/forumdisplay.php?fid=17) +----- Thread: html form/javascript help (/showthread.php?tid=67637) html form/javascript help by MeEtc on 10-24-2006 at 03:17 PM
I'm trying to make a form submit to a new popup window opened with javascript, close after loading, and have the form page simply refresh. code: The window will open and the script will open there. But, the form will not refresh and I don't know how to close the new window after it loads. I need all of the JS to be inline, not have an external script. can anyone help? RE: html form/javascript help by rav0 on 10-25-2006 at 07:36 AM
Couldn't you just get rid of the popup and have the page submit to itself? RE: html form/javascript help by hmaster on 10-25-2006 at 10:09 AM
Make script.php with the script you want to execute when they press submit and add at the end window.close. code:I think thats what you're trying to do? RE: html form/javascript help by MeEtc on 10-25-2006 at 12:14 PM
quote:No, I don't have access to the script itself quote:to wait for the script to execute before refreshing, as it impacts the form page. quote:I tried winFunc=window.open... and winFunc.document.onload=winFunc.close() combinaton, but get a security warning when trying to do it. quote:Will that actually submit the form info to script.php though? RE: html form/javascript help by hmaster on 10-25-2006 at 07:40 PM
Oh right you wanted to carry it over to the popup which is easily done through GET methods. code:And I tested this in a file called script.php: code:Which outputted: True Boo (this being what I put in the name input). Only downside is that you have to put all of the names of the input boxes that you want to send over to script.php in the window.open() function. |