View Categories

fluentform/email_body

Description #

This filter gives the option to modify the email body. It is called right before sending an email notification.

Usage #

Here is an example:

add_filter('fluentform/email_body',function($emailBody, $notification, $submittedData, $form){
	$targetFormId = 10;
	if($form->id != $targetFormId){
		return;
	}
	
	//your code here
	
	return $emailBody;
},10,4);

Parameters #

  • $emailBody (HTML) Html output of the body
  • $notification (Array) Notification settings data
  • $submittedData (Array) Submitted form data

Placement #

This code should be placed in the functions.php file of your active theme.

This filter is located in FluentForm\app\Services\FormBuilder\Notifications\EmailNotifications -> notify($notification, $submittedData, $form, $entryId = false)