Thursday, November 28, 2013

How to reset the PrestaShop admin password

Log into your site's cPanel and go to "File Manager"
Open /config/settings.php and copy the _COOKIE_KEY_ value
In the same file, check the database name in use for your PS install. The name will show as the value of "_DB_NAME_"

In your site's cPanel, go to PHPMyAdmin and open the database for your PrestaShop install
Look for a table called "employee" or if you are using prefixes, "ps_employee"
Check what email address is being used for your login in this table


1. Still in the database, go to "SQL" at the top and run the following query, where you replace the $VAR with the correct information

UPDATE employee SET passwd = md5(concat('$COOKIE_KEY', '$PASSWORD'))
WHERE email = "youremailaddress";

2. If your PrestaShop install uses table prefixes such as "ps_", amend the command to include the prefix:

UPDATE ps_employee SET passwd = md5(concat('$COOKIE_KEY', '$PASSWORD'))
WHERE email = "youremailaddress";

No comments: