FORUMS


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
Hooks Manager / Submission Pre-Parser
#1
Hi All,

Hope someone can help with this.

Scenario:
I have a multipage (6 pages) entry form with paypal integration and all of this works perfectly. Page 5 contains the register button and page 6 has the thank you details.

Problem:
Now what I wanted todo is use either the Hooks Manager or the submission parser to hook into the form submission at the point where the user presses the Register button. At this point I need to write a text file onto the server that will update an entries page with registrants and a few other bits of information.

Now the problem is I have not been able to find a hook that contains all of the submission data. The ft_get_form hook as well as the Submission Pre-Parser contain data only from the current page.

Question:
Is there a hook available that contains all of the data from a particular submission.

Thanks in advance

regards,

tombr....
Reply
#2
Hi Tombr,

Sure! The hooks are just for attaching your own code to a particular juncture in the code. What you really need is to call a core function within your Submission Pre-Parser (or Hooks Manager) rule to retrieve all the pertinent info.

Probably what you want is this guy: ft_get_submission_info.

If you call that function in your Submission Pre-Parser rule with the appropriate $form_id and $submission_id values, it will return a hash of database column names to values. Here's an example:

PHP Code:
$submission_info ft_get_submission_info($form_id$submission_id);
print_r($submission_info);
exit; 

Then put through a test submission. You should see the submission contents outputted to the screen. That should give you an idea of what info it contains and how to get at it. Once you're okay with it, just remove the print_r() and exit;

Hope this helps! Smile And good luck!

- Ben
Reply
#3
(Aug 28th, 2010, 10:32 AM)Ben Wrote: Hi Tombr,

Sure! The hooks are just for attaching your own code to a particular

...... cut .......

Hope this helps! Smile And good luck!

- Ben

Hi Ben

Thanks for that I will test it out during the week.

cheers,

tombr....
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)