Last active
March 24, 2023 12:09
-
-
Save divienginesupport/7f277cee99b96bb99c477900abdc54fe 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
// This filter will work for contact from conditional recipients. The custom_contact_recipient is the function name. | |
add_filter('df_contact_recipient', 'custom_contact_recipient', 10, 3); | |
// Use this filter will work for my create post form type. The custom_form_recipient is the function name | |
add_filter('df_notification_recipient', 'custom_form_recipient', 10, 3); | |
// This is the function for the contact form | |
function custom_contact_recipient( $mail_to, $form_id, $form_data ) { | |
/*** Your conditions go here ***/ | |
} | |
// This is the function for the create post form type - you can put conditions here for any form type | |
function custom_form_recipient( $mail_to, $form_id, $form_data ) { | |
/*** Your conditions go here ***/ | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment