Passing Data to Next Form???

liunx

Guest
:confused: I have a lengthy form that works quite well; however, I would like to break the form so that the visitor can enter the first half of the required form data, then move on to an upload page where they can upload a file, and then move on to the next and last half of the form for compleation.<br />
<br />
The object is to collect the Name, Address, and personal contact info, then let them upload their file, then transfer the collected data from the first form and the filename of the uploaded file to the last part of the form where they would finish entering additional instructions and then submit or POST.<br />
<br />
I have successfuly setup the forms and all the data is e-maied to me correctly. Just need to know if this is possible and any insight as to seting it up.<br />
<br />
Any help would be greatly appreciated.<!--content-->can you post it? that would really help<!--content-->The form is not ready just yet. Just a way to link them together.<!--content-->Dave Clark has an excellent example of doing this at the following link:<br />
<br />
<!-- m --><a class="postlink" href="http://www.DaveClarkConsulting.com/research/send_from.html">http://www.DaveClarkConsulting.com/rese ... _from.html</a><!-- m --><br />
<br />
(i am assuming that Dave Clark does not mind that i offer this... but i'm sure that i'll find out soon enough :eek: )<br />
<br />
known to bookmark DC solutions...<br />
:rolleyes: k<!--content-->kahki,<br />
<br />
Thanks for the tip. I tried the script, "posted below" bit it didn't carry the first first two field values over to the next form. And when I exicuted the POST to formmail it only listed the last 2 field values in the e-mail. I must be missing something.<br />
<br />
</html>First Form <br />
<br />
<html><head><title>Send From</title></head><br />
<body onLoad="document.myForm.form1_field1.focus();"><br />
<form name="myForm" action="send_next.html" method="GET"><br />
<p>Form1:</p><br />
<p><input type="text" name="form1_field1" size="20"></p><br />
<p><input type="text" name="form1_field2" size="20"></p><br />
<p><input type="submit" value="Submit"></p><br />
</form><br />
</body><br />
</html><br />
<br />
<br />
</html>2nd Form<br />
<br />
<html><head><title>Send Next</title><br />
<script language="JavaScript" src=http://www.webdeveloper.com/forum/archive/index.php/"../scripts/SearchString.js" type="text/javascript"></script><br />
</head><br />
<body onLoad="document.myForm.form2_field1.focus();"><br />
<form name="myForm" action="../..//cgi-bin/bformmail.pl" method="post"><br />
<script language=JavaScript><br />
<!-- // Begin<br />
var str = "";<br />
alert(self.location.search);<br />
var QueryString = new SearchStringExtract(window.top.location);<br />
for (i in QueryString) {<br />
if (str.length==0) str = "<p>Results:</p>\r";<br />
str += "<p>"+i+" = '"+QueryString+"'</p>\r";<br />
str += '<input type=hidden name="'+i+'" value="'+QueryString+'">\r';<br />
}<br />
if (str.length==0) str = "<p>No data sent.</p>";<br />
document.write(str);<br />
// End --><br />
</script><br />
<p>Form2:</p><br />
<p><input type="text" name="form2_field1" size="20"></p><br />
<p><input type="text" name="form2_field2" size="20"></p><br />
<p><input type="submit" value="Submit"></p><br />
</form><br />
</body><!--content-->src=http://www.webdeveloper.com/forum/archive/index.php/"../scripts/SearchString.js"Did you copy this file into your own Web directories?<br />
<br />
It should also be noted that a JavaScript solution will not work for 1 in every 10 users. All pages should be designed so they are still be usable when scripts are turned off or not supported.<!--content-->You could also use server side code such as PHP or CGI/Perl to do this. This solution would be the best, if you have access to any of these languages.<!--content-->You could also use server side code such as PHP or CGI/Perl to do this. This solution would be the best, if you have access to any of these languages.well... it's also a snap to do in ASP.<br />
So why is PHP or CGI/Perl the best way?<br />
<br />
The question should be:<br />
<br />
What - if any - server-side language do you have access to, Tom?<br />
<br />
;) k<!--content-->Originally posted by pyro <br />
You could also use server side code .... This solution would be the best.I'd have thought that you'd have know that I meant server side was best, not necessarily PHP or CGI... :rolleyes:<!--content-->hey... stop rolling your eyes at me pyro.... i'm on to you! ;) <br />
<br />
I promise that i will never again make a statement like that if you promise to include ASP as one of the server-side solutions.<br />
Deal?<br />
<br />
(and .... did you notice that i didn't quote you... just your post. I wasn't looking to call-you-out. I was just trying to make a point. It's a valid point though... right?)<br />
<br />
currently a bit pointy :eek: lol...<br />
;) k<br />
(hmm... maybe it's just cold. wink)<!--content-->:) <br />
<br />
I have complete control of the cgi-bin; pearl, php, cgi.<br />
<br />
I was under the impression that ASP needed to run on a windows platform. I have a semi-dedicated Unix server running Apache. <br />
<br />
Just thought it would be an easy thing to do...linking form pages. I guess everything is easy in theory.<br />
<br />
A server-side script would be great. But is there one out there?<!--content-->okay... no ASP = no khaki = :(<br />
<br />
the PHP Gang is sure to lend assistance though... i'm sure.<br />
(or whoever... just not the Gates Gang. That's your loss. ;) Just kidding!)<br />
<br />
good luck, Tom<br />
;) k<!--content-->I do appreciate your response none the less.<br />
<br />
Tom<!--content-->
 
Back
Top