473,398 Members | 2,525 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,398 software developers and data experts.

submit a form in a popup

42
Ok,
I hope I can get some help here,

Basically what I want to do, is to have my form to be submitted to a popup,
no problem there,
the problem is,

I want to initiate this from a button that is pressed on Another form, but no matter what I get it to open on another page not the popup.

something like :

Expand|Select|Wrap|Line Numbers
  1.  
  2. function popup(){
  3. window.open("", "newwin", "width=750,height=600,scrollbars=yes,resizable=yes");
  4. document.2ndform.submit();
  5. }
  6.  
  7. <from name="1stform">
  8. <input value ="button" type="button" onclick="popup()">
  9. </form>
  10.  
  11. <form name="2ndform" method="POST" action="xxx" target="newwin"  onsubmit="window.open("", "newwin", "width=750,height=600,scrollbars=yes,resizable=yes")">
  12. </form>
  13.  
when I use the "document.2ndform.submit();", the "onsubmit" of the 2nd form is skipped, and even if I open the popup in the function before submitting, the form is not targeted to that pop up, instead a new page opens.
Jan 5 '08 #1
1 1567
xhunter
42
Problem Solved.
thankx.
Jan 5 '08 #2

Sign in to post your reply or Sign up for a free account.

Similar topics

2
by: Matt | last post by:
Can form.submit() submit another form? In the following example, in page1.asp, it is fine to submit the current form: form1.submit(), and and I could see the value "Joe" in page2.asp. However, if I...
2
by: Terence Parker | last post by:
How does one go about submitting a form with a link - but submitting it to a new window AND to a page different to that described within the action="" option of the <form> tag? Say, for example,...
2
by: Johan | last post by:
I have a form that submit to the same page when double click on a product: <form method="post" action="quotes.asp" name="form1" onDblClick="javascript:formHandler()"> How can I submit the form...
1
by: Marshall Dudley | last post by:
I have a page where there are multiple submit buttons, some load the next page in the same window to continue, and some need to open the page in a popup for additional information. Therefore I...
2
by: jrefactors | last post by:
The following will submit the form data to popup by clicking the submit button. I want it will submit the form automatically to the popup, there is no submit button in this page. Basically this...
1
by: Matt Jensen | last post by:
Howdy I've got a ASP.NET webform page that pops up a window for a user to make a selection. Once they make a selection in this popup window, the form in the popup is submitted an update to the...
4
by: jwlum | last post by:
I have the following problem under Internet Explorer only: 1. User fills out form data (myform.php) and clicks a button that fires myFunction() 2. myFunction() spawns a "hello, world" popup page...
4
by: Gabriella | last post by:
Hi, I have a popup window that opens from a page on my website. This popup is a form with several fields. Upon submit button it redirects to a server side ASP page which writes all data to the...
11
by: V S Rawat | last post by:
using Javascript, I am opening a web-based url in a popup window. MyWin1=Window.Open(url, "mywindow") There is a form (form1) in the url in that popup window, I need to submit that form. ...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.