Created
February 25, 2019 18:50
-
-
Save Shelob9/aff5f0a6b4a0b289fa6f76ae622d6516 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
//Add email data to entry api response | |
add_filter( 'caldera_forms_api_entry_data', function ($data,\Caldera_Forms_Entry $entry){ | |
$form = $entry->get_form(); | |
$mailData = ( new \calderawp\WordPressPlugin\MailData($entry->get_entry_id(), $form ) )->getEmailData(); | |
$data[ 'mailData'] = $mailData; | |
return $data; | |
},10,2); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment