SOHO : Small Office Home Office
Freeware - Opensource software tips, tricks, tweaks & fixes for managing, securing, improving the performance of SOHO Desktop, Laptop, Networks

Monday, October 10, 2016

reset wordpress user password

On updating my wordpress user password I forgot...

Refering : https://codex.wordpress.org/Resetting_Your_Password

I opted for the ftp option but instead of downloading and uploading I logged in through ssh and edited the file. Super easy

1. Login to your site via FTP / SSH  and download or edit your active theme's functions.php file.
2. Edit the file and add this code to it, right at the beginning, after the first <?php:
wp_set_password( 'password', 1 );
Put in your own new password for the main admin user. The "1" is the user ID number in the wp_users table.
3. Upload the modified file back to your site.
4. After you then are able to login, make sure to go back and remove that code. It will reset your password on every page load until you do.
Next step is hardening wordpress

No comments:

Post a Comment