Forums

This topic is locked

Submitting DB Data "hidden" to Multiple Form Pages

Posted 23 Apr 2008 09:19:01
1
has voted
23 Apr 2008 09:19:01 Alan Colmes posted:
Many sites have user forms consisting multiple pages for ease of use instead of having one big forms page. They break up the forms into several smaller ones.

I would like to submit data from my DB to their multiple forms automatically. It seems like I can only do it once. I'm using the <body onLoad="document.FORM1.submit();"> for the first form. At that point, I'm trying to call the second <body onLoad="document.FORM2.submit();"> action to submit the hidden form elements to their second remote form page. Can a php script be run in the background to launch the second submission? The browser page needs to launch and be in focus in order to then automatically submit onLoad of the second and third submissions.

Now for Form2+, I'm trying to automatically initiate the data required from my DB for their form2 page. Once Form1 submits, I can't seem to get the second action to pass form2 automatically. Is there a way to do this? Depending on the number of forms they have, I would like to automatically submit the data.

Any ideas?


Replies

Replied 23 Apr 2008 13:34:35
23 Apr 2008 13:34:35 Alan C replied:
Hi Alan,
I've done similar things, passing inputs from one page to another, but have always done them using session variables or using a session to track the user and then picking up data from the database to put into the fields on the new pages.

Generally I code the php partly with dw and partly by hand, quite a lot of learning involved to get up and working doing it that way, I guess other people would do it all in dw, but I've found that I couldn't always find what I wanted and being a coder by background I found it easier this way.

There's a good example of a login and admin system here
www.evolt.org/PHP-Login-System-with-Admin-Features
it tracks users with sessions - I used it as the basis of my admin section

Generally I put things into fields like this . . .

<pre id=code><font face=courier size=2 id=code> &lt;tr &gt;
&lt;td width="220" align="right"&gt;fax contact &lt;/td&gt;
&lt;td width="250" &gt;&lt;input type="text" name="p_fax" value="&lt;?php echo $row_rsPropertyUpdate['p_fax']; ?&gt;" size="32" /&gt;&lt;/td&gt;
&lt;/tr&gt;
</font id=code></pre id=code>

sorry this is not a specific solution but it might stimulate some ideas and other responses

Reply to this topic