Hello. I have a form on my site with a custom PHP handler. Per the plugin documentation, I have added custom PHP code to ensure the form data is correctly sent to the plugin, so the plugin can record the data. That has been working without issue for several months (or maybe years by now). I have now added a new field to this form, and have modified my PHP code to ensure this new field is sent to the plugin. But when I submit the form, the plugin does not recognize this new field. Specifically, if I open Dashboard-..Contactic–>Overview, and select the form in-question, I can see this form submission. The page displays all of the fields except this new field. Any ideas how to troubleshoot? I should note that in my PHP error log, there is an entry:
PHP Notice: Undefined index: original_referer in /home/horizon/domains/horizonhomes-samui.com/dev/public/wp-content/plugins/contactic/ContacticPlugin.php on line 935
I’m not sure if that is related to my issues.
My custom PHP code to send form data to the plugin is below. The new field is $form_data[‘propid’]:
$form_data = array( 'name' => $_POST['name'], 'email' => $_POST['email'], 'email-cp' => $_POST['email'] . ",", 'message' => $_POST['message'], 'propid' => $_POST['propid'], 'page' => esc_url( get_permalink( )) ); error_log(print_r("Print form data",true)); error_log(print_r($form_data,true)); $title = "Inquiry Form - Agents Page"; // Prepare data structure for call to hook $data = (object) array( 'title' => $title, 'posted_data' => $form_data, 'uploaded_files' => array() ); // Call hook to submit data do_action( 'cfdb_submit', $data );
- The topic ‘Form field not recognized by plugin’ is closed to new replies.