Hi @sandracorsivalab,
Please try deny filter after removing the space at the end of filter name.
Please have a look at the screenshot.
Filter to change the Subject of the deny email:
add_filter('new_user_approve_deny_user_subject', 'nua_change_denied_email_subject', 10);
function nua_change_denied_email_subject($subject) {
$new_subject = '[Your Gifts & (S) Private Limited] Registration Denied'; // here replace any subject here text with your subject between single quotes.
return $new_subject;
}
Filter to change the sender name and email:
add_filter( 'new_user_approve_email_header',function( $headers){
$admin_email="[email protected]"; //enter sender email
$from_name = 'Sender Name Here'; //enter sender name
return array( "From: \"{$from_name}\" <{$admin_email}>\n" );
},99,1 );
Filter to change the content of the deny email:
add_filter( 'new_user_approve_deny_user_message', function(){
$message='You have been denied access to Gifts & (S) Private Limited.';
return $message;
},99);
Please see the screenshot.
Let us know if you have any questions.
Thank you