Friday, October 11, 2013

How to reset admin details in Prestashop

1) Login into your Hosting Control Panel and open PHPMyAdmin tool (or the tool which is used for managing databases). If you’re not sure how to locate and open it, please consult with your Hosting Provider.


2) From the list in the left pane, you should select the database which you created for your Prestashop CMS.


presta_1


 


3) You should see a list of tables that are used in the selected database, but we don’t need to work with any of them directly. Click on the SQL tab


presta_2


 


4) Now paste the following line of code into “Run SQL query/queries” text area

UPDATE `ps_employee` SET `passwd` = MD5(‘<_COOKIE_>password’) WHERE `ps_employee`.`id_employee` = 1;


Before pressing the GO button to execute this query, you need to modify it a bit:


- replace the <_COOKIE_> with the actual cookie code, which you can find in the /config/settings.inc.php file of your Prestashop engine. In my case the value is WRhw145L5k724dJEFti0a0nHuDjC8AWvbioCWOjA2cebIbv48VjEfzX2

The code value will be different for your site, as this is unique key generated for the store during installation




<?php

define('__PS_BASE_URI__', '/gordon/presta135/');
define('_THEME_NAME_', 'theme065');
define('_DB_NAME_', 'gordon_presta135');
define('_DB_SERVER_', 'localhost');
define('_DB_USER_', 'root');
define('_DB_PREFIX_', 'ps_');
define('_DB_PASSWD_', '');
define('_DB_TYPE_', 'MySQL');
define('_COOKIE_KEY_', 'WRhw145L5k724dJEFti0a0nHuDjC8AWvbioCWOjA2cebIbv48VjEfzX2');
define('_COOKIE_IV_', 'mPBcrcuj');
define('_PS_VERSION_', '1.3.5.0');

?>

 




- replace the word “password” with the new password you want to use for the admin login


The final result should look similar to the screenshot below. Note! there must be no spaces or any additional symbols between the cookie code and the password


presta_4


 


5) Now press the GO button to execute the query. If it has been executed succesfully you should get the following message


presta_5


 



How to reset admin details in Prestashop

No comments:

Post a Comment