Solved

Submitting Two Forms with one click

Posted on 1997-07-10
2
181 Views
Last Modified: 2006-11-17
Is it possible to send two forms with one click?
0
Comment
Question by:6100
2 Comments
 
LVL 5

Accepted Solution

by:
icd earned 50 total points
ID: 1268405
It is possible to send two forms in two separate frames with one click but not two forms in the same frame. To do so would mean a conflict since which script should output to the current frame?

0
 
LVL 1

Expert Comment

by:pmcintos
ID: 1268406
You can use a frame maker page that divides the page up into two frames:   make one frame 100% width or height whichever you are doing....
Submit form #1 in the visible frame (that is the 100% sized one )
Submit form #2 in the invisible frame
Make it so the response from the appropriate form is submitted in the visible frame.
This will in effect submit one of the forms in the background...


Oh yeah....how to submit them both on the same click.  Have them click the submit button for one of the forms.  Give this form the event
onSubmit=" return myfunction()"
now here is the function:
function myfunction() {
  document.thesecondformname.submit();
  return true;
}

now straight above the second form write in the line:
<base target="parent.hiddenframename">
This will rifle this form off with the response directed at the hidden frame.  I hope this helps you...
The answer above doesn't seem to be very specific...
if you want any further explaination just comment this question and I will come check it out.

Pete
0

Featured Post

Free Tool: ZipGrep

ZipGrep is a utility that can list and search zip (.war, .ear, .jar, etc) archives for text patterns, without the need to extract the archive's contents.

One of a set of tools we're offering as a way to say thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

In this article, we'll look how to sort an Array in JavaScript, including the more advanced techniques of sorting a collection of records either ascending or descending on two or more fields. Basic Sorting of Arrays First, let's look at the …
This article will give core knowledge of JavaScript and will head in to your first JavaScript program. I am Durvesh Naik and I am here to deal with this series of JavaScript. I will teach you JavaScript in part wise , as its quite boring to read big…
The viewer will learn the basics of jQuery, including how to invoke it on a web page. Reference your jQuery libraries: (CODE) Include your new external js/jQuery file: (CODE) Write your first lines of code to setup your site for jQuery.: (CODE)
The viewer will learn the basics of jQuery including how to code hide show and toggles. Reference your jQuery libraries: (CODE) Include your new external js/jQuery file: (CODE) Write your first lines of code to setup your site for jQuery…

860 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question