WordPress.org

Ready to get started?Download WordPress

Forums

Register Plus
Remove auto-generated Password message (6 posts)

  1. farrelldoc
    Member
    Posted 3 years ago #

    How do you eliminate the following message after a user logs in?

    Notice: You’re using the auto-generated password for your account. Would you like to change it to something you’ll remember easier?

    They are setting their own PW, so they shouldn't see this message.

    Thanks,
    Karen

    http://wordpress.org/extend/plugins/register-plus/

  2. otternox
    Member
    Posted 3 years ago #

    anyone come up with a solution yet?

  3. WPsites
    Member
    Posted 3 years ago #

    Just had to do this a few minutes ago and thought I would share the code with everyone. It's pretty straight forward

    <?php
    //disable password nag
    function stop_password_nag( $val ){
    return 0;
    }
    add_filter( 'get_user_option_default_password_nag' ,'stop_password_nag' , 10 );
    ?>

  4. Tevya
    Member
    Posted 3 years ago #

    WPsites, where did you put this code? Just in the functions.php file?

  5. Tevya
    Member
    Posted 3 years ago #

    For me, putting this in functions.php got rid of the password nag:

    function remove_default_password_nag() {
    global $user_ID;
    delete_user_setting('default_password_nag', $user_ID);
    update_user_option($user_ID, 'default_password_nag', false, true);
    }
    add_action('admin_init', 'remove_default_password_nag');
  6. nguyenjustin
    Member
    Posted 3 years ago #

    You would be adding the above code of :

    function stop_password_nag( $val ){
    return 0;
    }
    add_filter( 'get_user_option_default_password_nag' ,'stop_password_nag' , 10 );

    to the file user.php

    which is located in the folder: /wp-admin/includes

    Cheers mate.

Topic Closed

This topic has been closed to new replies.

About this Plugin

About this Topic