WordPress.org

Ready to get started?Download WordPress

Forums

[resolved] Show user password on screen (2 posts)

  1. phillbooth
    Member
    Posted 1 year ago #

    Hello I have a made a nice script for my site where a user can register and see there pre-generated password on screen however I am having trouble decrypting it.

    The code below gets the password in its MD5 form but how to unlock with salt? there must be a way as the WP welcome/password reset email shows the given password.

    $user = get_userdatabylogin($_REQUEST['youremail']);
    $user->user_pass
  2. phillbooth
    Member
    Posted 1 year ago #

    Got round this by simply grabbing the wp_generate_password() return and passing that to template

    $newpassword=wp_generate_password();
    wp_create_user( $youremail, $newpassword, $youremail );

Topic Closed

This topic has been closed to new replies.

About this Topic