Home › Forums › Quform WordPress › Submit events & Form Data
This topic is: not resolved
- This topic has 3 replies, 2 voices, and was last updated 4 years, 6 months ago by Ally.
Viewing 4 posts - 1 through 4 (of 4 total)
- AuthorPosts
- August 22, 2019 at 7:00 pm #29841welightspeed_webParticipant
Hi,
I’m trying to add all form data to a CRM via API when someone submits.
How can I trigger my own code to run when a form is submitted and how do I access the submitted form data?
ThanksAugust 27, 2019 at 10:40 am #29856AllySupport StaffYou don't have permission to view this content. Please log in or register and then verify your purchases to gain access.
September 5, 2019 at 3:50 pm #29910welightspeed_webParticipantThanks for your response.
I’ve had some further trouble with the action not having the correct number of arguments:
I’m using PHP 7.2.add_action('quform_post_process_4', function (array $result, Quform_Form $form) { $data = array( 'name' => $form->getValue('quform_4_5'), 'email' => $form->getValue('quform_4_7'), 'notes' => $form->getValue('quform_4_9'), );
<br /> <b>Fatal error</b>: Uncaught ArgumentCountError: Too few arguments to function {closure}(), 1 passed in /home/tradeoak/staging/5/wp-includes/class-wp-hook.php on line 288 and exactly 2 expected in /home/tradeoak/staging/5/wp-content/themes/tradeoak/functions.php:270 Stack trace: #0 /home/tradeoak/staging/5/wp-includes/class-wp-hook.php(288): {closure}(Array) #1 /home/tradeoak/staging/5/wp-includes/plugin.php(208): WP_Hook->apply_filters(Array, Array) #2 /home/tradeoak/staging/5/wp-content/plugins/quform/library/Quform/Form/Processor.php(172): apply_filters('quform_post_pro...', Array, Object(Quform_Form)) #3 /home/tradeoak/staging/5/wp-content/plugins/quform/library/Quform/Form/Controller.php(245): Quform_Form_Processor->process(Object(Quform_Form)) #4 /home/tradeoak/staging/5/wp-content/plugins/quform/library/Quform/Form/Controller.php(178): Quform_Form_Controller->handleProcessRequest() #5 /home/tradeoak/staging/5/wp-includes/class-wp-hook.php(286): Quform_Form_Controller->process('') #6 /home/tradeoak/staging/5/wp-includes/cl in <b>/home/tradeoak/staging/5/wp-content/themes/tradeoak/functions.php</b> on line <b>270</b><br />
September 13, 2019 at 10:56 am #29931AllySupport StaffYou don't have permission to view this content. Please log in or register and then verify your purchases to gain access.
- AuthorPosts
Viewing 4 posts - 1 through 4 (of 4 total)
- You must be logged in to reply to this topic.