I have the following function in my themes function.php:
function user_profile_update( $user_id ) {
$site_url = get_bloginfo('wpurl');
$user_info = get_userdata( $user_id );
$to = $user_info->user_email;
$subject = "Profile Updated: ".$site_url."";
$message = "Hello " .$user_info->display_name . "
Your profile has been updated!
Thank you for visiting
".$site_url."";
wp_mail( $to, $subject, $message);
}
add_action( 'profile_update', 'user_profile_update');
This basically sends an email everytime a user updates there profile.
The email comes through fine but i get it 3-4 times. Does anything look out of place with the above?