Riparian Posted March 8, 2011 Share Posted March 8, 2011 Scenario. I have a simple form and on the same page a link to open a popup window. The client completes the form then click the upload link. In the popup window the client uploads a file. Problem On closing the popup window the main page is refreshed (to indicate the upload was successful) As the form was not initially submitted - All Form Data is then Lost Question Is there a way of submitting the form and opening a popup window at the same time (to preserve the data entered by the client) or is there another fix for this problem ? Any help is greatly appreciated. Cheers Quote Link to comment Share on other sites More sharing options...
Mahngiel Posted March 9, 2011 Share Posted March 9, 2011 if you're passing the information to the popup menu from the form they've filled out, you could use the GET method and instruct the pop up to pull it's info from the url Quote Link to comment Share on other sites More sharing options...
Riparian Posted March 9, 2011 Author Share Posted March 9, 2011 Thank you for the reply. To be able to obtain the input info in the get variables I still have to submit the form. My problem is that I do not know how to open a popup window immediately after the form is submitted while still keeping the parent window open . Quote Link to comment Share on other sites More sharing options...
Krash Posted March 9, 2011 Share Posted March 9, 2011 Not sure what you're trying to do, but you can add an onClick event to the 'submit' input that will submit the form data and open a popup at the same time. <input type="submit" value="Upload" onClick="window.open('http://www.your_url.com/popup_content.htm','popup_player','height=200,width=300,top=150,left=300,scrollbars=no')"> The popup will open over the parent window. Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.