Your cart is currently empty!
Receiving Notification Email for Old Registrant
—
by
Hey! Hope you’re well…
Two of my clients have experienced this. They’re receiving notifications that there is a ‘New’ registration but it’s for an old, already approved registrant. As a reminder, we used Affiliates Pro for fundraising. It’s happening after the fundraiser is over so the notifications are in relation to an inoperative affiliate. But when the affiliate is asked if they tried to re-register or restart their fundraiser, the answer has been ‘no’. In fact, they haven’t even been in their account at all. So, I’m not sure what’s triggering this.
It happened twice in February for one client and twice in March/April for another.
I’ve traced the issue back to code that was added to the functions.php file. I believe that you sent me this so that we could notify someone other than the admin when a registration is submitted. The email being received is sent to info@domain.com address (not the admin email address) and it has the matching subject line and contents from the php code. So, it looks just like a new registration, but we know the person isn’t new and there isn’t a pending registration in the system.
Here’s the code from the functions.php file:
add_action( ‘affiliates_added_affiliate’, ‘extra_email_affiliates_added_affiliate’ );
function extra_email_affiliates_added_affiliate( $user_id ) {
$user = new WP_User( $user_id );
$user_login = stripslashes( $user->user_login );
$user_email = stripslashes( $user->user_email );
/* Here you new email */
$email = “info@happyvalleysoupcompany.com”;
$blogname = wp_specialchars_decode( get_option( ‘blogname’ ), ENT_QUOTES );
$message = sprintf( __( ‘New fundraiser registration on your site %s:’, AFFILIATES_PLUGIN_DOMAIN ), $blogname ) . “\r\n\r\n”;
$message .= sprintf( __( ‘Username: %s’, AFFILIATES_PLUGIN_DOMAIN ), $user_login ) . “\r\n\r\n”;
$message .= sprintf( __( ‘E-mail: %s’, AFFILIATES_PLUGIN_DOMAIN ), $user_email ) . “\r\n”;
if ( get_option( ‘aff_notify_admin’, true ) ) {
@wp_mail( $email, sprintf( __( ‘[%s] New Fundraiser Registration’, AFFILIATES_PLUGIN_DOMAIN ), $blogname ), $message );
}
}
Any thoughts?
Thanks! -Erica
Comments
2 responses to “Receiving Notification Email for Old Registrant”
Thanks for exploring the issue, Eugen! No worries on the delay.
Hi Erica,
Good morning! I trust you are well and safe!
First off, please permit me to apologize for the delayed response to your inquiry. Please forgive me.
I am sorry you are experiencing this. Please allow me to test this and get back to you ASAP.
STAY SAFE and I wish you a very fine and productive day ahead!
Best,
Eugen.