Hello,
I have successfull transfeared all store information from Prestashop to Opencart, but I have 1 main problem at this moment.
Prestashop customer passwords doesnt work at opencart. I have transfear password fields, but i think here is problem is with password encryption in prestashop.
Maybe somebody know, how to migrate customers from prestashop to opencart? what can I do to make it work?
I have successfull transfeared all store information from Prestashop to Opencart, but I have 1 main problem at this moment.
Prestashop customer passwords doesnt work at opencart. I have transfear password fields, but i think here is problem is with password encryption in prestashop.
Maybe somebody know, how to migrate customers from prestashop to opencart? what can I do to make it work?
Last edited by Lexys on Wed Jan 29, 2014 3:04 am, edited 1 time in total.
I had this problem a few years ago and what I did was reset everyone's password to their last name in lower case letters. Then I sent them all an email notifying them of the upgraded software and its new features, their password reset (and how to change it once they logged in to anything they wanted), and gave them a % off their first order on the new cart.
It encouraged customers to come check us out again and boosted sales during the transition too
It encouraged customers to come check us out again and boosted sales during the transition too

Running Opencart v3.0.3.9 with multi-stores and the default template from https://www.labeshops.com which has links to all my stores.
I thinking about itlabeshops wrote:I had this problem a few years ago and what I did was reset everyone's password to their last name in lower case letters. Then I sent them all an email notifying them of the upgraded software and its new features, their password reset (and how to change it once they logged in to anything they wanted), and gave them a % off their first order on the new cart.
It encouraged customers to come check us out again and boosted sales during the transition too

Opencart passwords are code only by md5 and thats all?
maybe do you have script to make this step more easy?

I think, that I need to add prestashop password encryption to opencart, then I'll make password work prestashop and opencart, but at this moment I dont know how to do it 
--------------------------
SOLUTION IS FIND!
I have edit /system/library/customer.php file.
After public function login($email, $password, $override = false) { (46 line)
add fallowing code:
$key_login = 'key from prestashop settings.inc file';
above 51 lines edit this query:
$customer_query = $this->db->query("SELECT * FROM " . DB_PREFIX . "customer WHERE LOWER(email) = '" . $this->db->escape(strtolower($email)) . "' AND password = '" . $this->db->escape(md5($password)) . "' AND status = '1' AND approved = '1'");
And update to:
$customer_query = $this->db->query("SELECT * FROM " . DB_PREFIX . "customer WHERE LOWER(email) = '" . $this->db->escape(strtolower($email)) . "' AND password = '" . $this->db->escape(md5($key_login.$password)) . "' OR password = '" . $this->db->escape(md5($password)) . "' AND status = '1' AND approved = '1'");
After that customers from prestashop, can login with thems own passwords
BRAVO!

--------------------------
SOLUTION IS FIND!
I have edit /system/library/customer.php file.
After public function login($email, $password, $override = false) { (46 line)
add fallowing code:
$key_login = 'key from prestashop settings.inc file';
above 51 lines edit this query:
$customer_query = $this->db->query("SELECT * FROM " . DB_PREFIX . "customer WHERE LOWER(email) = '" . $this->db->escape(strtolower($email)) . "' AND password = '" . $this->db->escape(md5($password)) . "' AND status = '1' AND approved = '1'");
And update to:
$customer_query = $this->db->query("SELECT * FROM " . DB_PREFIX . "customer WHERE LOWER(email) = '" . $this->db->escape(strtolower($email)) . "' AND password = '" . $this->db->escape(md5($key_login.$password)) . "' OR password = '" . $this->db->escape(md5($password)) . "' AND status = '1' AND approved = '1'");
After that customers from prestashop, can login with thems own passwords

BRAVO!
Great post
It would be helpful for people migrating from prestashop to opencart
It would be helpful for people migrating from prestashop to opencart

Donate here to show support if you think I have helped you today!
Opencart Documentation
Who is online
Users browsing this forum: No registered users and 11 guests