bhubbard
11/7/2013 - 11:22 PM

Gravity Forms - Output Fields

add_action("gform_after_submission", "set_post_content", 10, 2);
 function set_post_content($entry, $form){
 //Gravity Forms has validated the data
 //Our Custom Form Submitted via PHP will go here
 
 // Lets get the IDs of the relevant fields and prepare an email message
 $message = print_r($entry, true);
 
 // In case any of our lines are larger than 70 characters, we should use wordwrap()
 $message = wordwrap($message, 70);
 
 // Send
 mail('EMAIL ADDRESS', 'Getting the Gravity Form Field IDs', $message);
 }