Wordpress background password Forgot retrieval method summary

Source: Internet
Author: User
Tags md5 phpmyadmin wordpress login wordpress login page

1. Wordpress built-in password retrieval method

If the email address of your admin account is correct, click "forgot password" on the Wordpress logon page based on the common password retrieval steps ?" Enter the admin or email address. Then, you will receive a password restart email and click the restart link in it. You will receive an email containing the user name and password later.

This is the same as the steps for all Wordpress users to retrieve their passwords. The other four methods we will introduce below are that you may not change the admin account's email address, and you will not be able to accept the password.

2. Run the Mysql statement to modify the Wordpress password.

Use tools such as Phpmyadmin to log on to your database management and execute the following statement:

The code is as follows: Copy code

"Update user set password = password (" new password ") where user =" username ";"

To update your Wordpress password.

3. Use the php file to change the Wordpress password

Create a new pwd. Php file and add the following to it:

The code is as follows: Copy code

Echo md5 ("your password ");

Upload to the root directory of the host and add

Http: // your domain name/pwd. php, and then connect to your database for execution.

The code is as follows: Copy code

Update wp_users set user_pass = "string displayed when executing pwd. php"

Where user_login = "admin ";

OK. Now you can use your own password to enter the administrator account.

5. Change the MD5 value to retrieve the Wordpress password.

After WorePress is installed, the password is automatically provided. I have been logging in automatically, so I forgot the password a month later. WP uses MD5 to save the password, so the password is irreversible. You can use the database to change the password in the background, so you can log on to phpmyadmin. The first step after logging on is to select a database.

Change the MD5 password to "5d41402abc4b2a76b9719d911017c592 & Prime;
Return to the WordPress login page and log on with the password "hello.

 

The code is as follows: Copy code

<? Php
// Password resetter
Include ("wp-config.php ");
Include ("wp-blog-header.php ");
If (empty ($ _ POST ['emergency _ pass']) {
?>
<Form method = "post">
Set admin password: <input name = "emergency_pass" type = "password"/>
<Input type = "submit"/>
</Form>
<? Php
} Else {
$ SQL = "UPDATE ". $ wpdb-> users. "SET user_pass = '". md5 ($ _ POST ['ergency _ pass']). "'Where User_login = 'admin '";
$ Link = $ wpdb-> query ($ SQL );
Wp_redirect ('WP-login. Php ');
Exit ();
}
?>

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.