BuddyDev

Search

WordPress User Login Notifier

  • Participant
    Level: Master
    Posts: 222
    Mike (DesignServe) on #26171

    Hi Brajesh,

    I love the plugin WordPress User Login Notifier. It is so useful for troubleshooting my site and seeing what issues users are having so that I can help out.

    1 – Would it be possible to add the user’s email address into the notifications so that I don’t have to go in the site to search and find them, then copy the email address to my email program if I want to email them? (I can’t click email addresses for mailto links because I use different browsers and email clients for work purposes, the work ones have to be the defaults).

    2 – I considered that I would like to send a ‘help’ email to them if they fail to log in. It would tell them how to get help like changing their password or use my contact form for example. However, we don’t want that to be sent to spammers. I leave it here as an idea for you. Perhaps a backend place where we could see a log of the notifications and click to send automated canned responses would be an idea (a premium version perhaps).

    Thanks,
    Mike

  • Keymaster
    (BuddyDev Team)
    Posts: 21796
    Brajesh Singh on #26175

    Hi Mike,
    Thank you for using the plugin.
    1. Please add following code to your bp-custom.php

    
    
    /**
     * Append User email to the admin notifications messages by the WordPress user login Notifier.
     *
     * @param string  $message message.
     * @param WP_User $user user object.
     *
     * @return string
     */
    function wpul_custom_append_user_email_to_message( $message, $user ) {
    	return $message . '\n Email:' . $user->user_email . '\n';
    }
    
    add_filter( 'wpuln_failed_login_admin_email_message', 'wpul_custom_append_user_email_to_message', 10, 2 );
    add_filter( 'wpuln_successful_login_admin_email_message', 'wpul_custom_append_user_email_to_message', 10, 2 );
    
    

    That will add email to the message.

    2. Thank you for the suggestion. At the moment, we do not store the log at all. It may be a helpful feature in future.

    Regards
    Brajesh

You must be logged in to reply to this topic.

This topic is: not resolved