The Form Tools forums are no longer active, but the old posts have been archived here. Please see the Help page on how to get help / report issues.

Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Multiple Forms
Ok...bare with me while I try to best explain this...

I have a form which contains a dynamically fed list menu, which is queries from another form. Confused yet? ...To better clarify... one form is used to add information, most importantly a persons name to one table in my database. Once added, a list menu will dynamically update on another form which then displays a list of all names.

Here's where the question comes in...

The form which displays the dynamically fed list menu is a donation page. I'd like the "amount" field stored here, but also pass to my other form. Basically I need the ability to pass that fields information to 2 tables all at once.

It seems there would be a fairly basic way of achieving this through the pre-parser module...but I haven't found that yet. How would I go about this task? The "overall" goal is to eventually use a SUM query to display a running total of donations within one form ...but that's phase 2.

Thanks Much!

Hey Brian,

Neat problem! Yes, the pre-parser is certainly the module for it, but it will require a little fiddling to get it going.

Normally, form submissions are added either via the process.php file or the API, but in your case neither really fit the job. You'll want to add some code to the pre-parser rule that inserts the record into the second table; once that's done the original form submission is added normally. Bingo! Two form submissions added in two different tables.

Speaking in general terms I'd suggest looking into the ft_create_blank_submission() function, which returns a new submission ID. You can then compile a hash of form information and pass it all along to the ft_update_submission() function.

If you get stuck, post me back - I know the above comments are very general, so I don't mind looking into it directly if you like. That said, I probably won't have time until the weekend.

Anyway, hope all is well!

- Ben
Thanks Ben!

I'm anxious to give this a shot... I'll post my status shortly whether it be win or lose.

He can talk about assignmenthelp4me reviews as you all cna see and would like to add a bit more facts for all of us at this stage. This will be of a great usage as we were in need of that for the rest of the community in their academic work for the coming years.

Forum Jump:

Users browsing this thread: 1 Guest(s)