Know-how 11.07.2019 customer, export, import, password

Imported customers - problem with passwords

If you migrated customers and if passwords of old accounts do not work - read it. You will find solution for this problem.

If you are struggling with customers migration from one shop to another with properly working passwords - this is an article for you. Migrating customers between shops has one disadvantage related to passwords. Simply saying - passwords of customers from source shop will not work in shop, where you imported customers. It is because each installation of prestashop is secured with special unique charcode named "cookie key". If you want to use passwords from shop A, in shop B you need to transfer also cookie key from old shop, to new shop. Below you can find information how to do it.
 
password export import prestashop problem

if you move customers between shops, from 1.5.x / 1.6.x to 1.5.x / 1.6.x
  • in source shop:
    • open /config/settings.inc.php file 
    • there is a code like:
      define('_COOKIE_KEY_', '2YcmZa0kQWgXZKOecjAZc6VPKVxaA9iNnonvV6os4yI9smxGKF3Ux8zJ');
    • this is an unique charcode called "cookie key" that i mentioned at the begining of my email: '2YcmZa0kQWgXZKOecjAZc6VPKVxaA9iNnonvV6os4yI9smxGKF3Ux8zJ' (in your shop it will be different). Copy it
  • in target shop:
    • open /config/settings.inc.php file 
    • replace existing COOKIE KEY there with cookie key that you copied from source store.
    • save changes to file

Before you will follow the steps i described above - please do a backup of your COOKIE KEYS for both shops. Just in case.
After this all passwords of customers will work properly,  You - as a shop admin - will need to "reset" admin password. 
 
Migrating customers with passwords from prestashop 1.6 to prestashop 1.7:
In case of migrating working passwords of customers between ps in version 1.6 to ps in version 1.7 is much more complicated. In this case it is required to change the way of how correctness of password is checked in prestashop 1.7. This requires core code changes. If you are looking for a dedicated service - check: migrating passwords of customers between prestashop 1.6 and 1.7.
Zdjęcie autora: Milosz Myszczuk

Artykuł napisany przez Milosza Myszczuka, eksperta PrestaShop i oficjalnego moderatora społeczności PrestaShop. CEO i założyciel agencji interaktywnej VEKIA. Dowiedz się więcej.

If you like this article, support our work!

Comments