Jump to content

Prestashop migration problem


Recommended Posts

Hello,

 

Here is a quick backstory of my problem:

 

A friend of mine have got a website that uses prestashop ver 1.3.6.0, actualy running and working fine, and still online.

 

That friend can't manage the website himself ( and doesn't know anything about how a website works ), so another friend of him manages it for him, but he's lacking time to do any changes to the website anymore, so the first wants me to take over the website, and manage it.

 

I have no experience of prestashop, but it seems rather easy to modify.

 

First i wanted to edit the website with an offline copy, before putting it back online, so the second friend gave me a copy of the whole www root, and a copy of the mysql database so i can work on it.

 

Using easyphp on a windows 7 x64 PC ( last version of easyphp to date ), i proceed to put the www content to the www folder of easyphp, i create a new user and password for mysql to match the site config ( so i don't have to modify it ), giving all privileges to said user, and i import the database where it's supposed to be for the website to work.

 

When i go to 127.0.0.1 to see how it goes, first i notice that one of the frontpage module (carousel) isn't working, however, any other part of the website works fine except one other important thing...

 

When i log to the backoffice using the email and password, it gives me the error messaage "Wrong email or password", but using the same email and password works fine on the live website. This gets me confused.

 

Am I doing something wrong, or is this a common migration issue?

As I said, i never used prestashop before, but i don't think i'm doing anything wrong.

Also, the website will soon be delocalized, so editing the live website will work, but only for a time, so if there are migration issues I should be aware of, I must know them.

 

Thanks in advance for your help.

 

Best regards.

Link to comment
Share on other sites

Hello Mike Kranzler,

 

First, thanks for the quick answer, I wasn't really waiting for a reply until tomorrow.

 

After reading your guide "Moving PrestaShop", i've come to conclude that i've done pretty much everything that was written in there,and in the right order.

 

I'll do a step-by-step summary of what I did, and compare it to the guide.

 

1. Put your shop in maintenance mode, so as to not lose new customers or orders while moving the data.

 

Go to your back-office, and under the "Preference" tab, set the "Enable shop" option to "No".

 

 

This is something I don't really know if the second friend did before giving me the www root folder. However I tried to extract the website again while it was offline, but it didn't change anything.

 

 

Move your files

  • Make a backup of all the files: connect to your FTP server, and copy all the files and folders to your local hard-drive.
  • Transfer your files to your new host: Connect to the FTP server for your new host, and copy all the files and folders that you just downloaded to your local hard-drive, as is.

Move your data

  • Make a backup of you database (a "dump"): connect to phpMyAdmin, click on the "Export" tab, select the database of your PrestaShop installation, and click the "Go" button. Save the downloaded file on your hard-drive. If phpMyAdmin times out before it is able to export all your data, contact your host.
  • Transfer the SQL dump to the new database: connect to the new server's phpMyAdmin, click on the "Import" tab, click the "Browse..." button, find the SQL file you just downloaded, and click the "Go" button to upload it. If phpMyAdmin times out before it is able to import all your data, contact your new host.

This is pretty much what I did, taking the www root, and putting it in easyphp's www root, and I used the export/import in PhpMyadmin, which have been completed with no error.

 

 

Configuration

  • On the new server, open the /config/settings.inc.php file and update the settings for the new database server (with your own settings instead of the examples here):
    • define('_DB_SERVER_', 'sql.domainname.com');
    • define('_DB_NAME_', 'prestashop');
    • define('_DB_USER_', 'PS-user');
    • define('_DB_PASSWD_', 'djsf15');
    • define('_DB_PREFIX_', 'ps_');

    [*](1.4 and earlier) In that same file, update the Base URI setting ('/' being the server root):

    • define('__PS_BASE_URI__', '/prestashop/');

After taking a look at the configuration file, nothing needs to be changed, as mentioned earlier, I made sure that my local Mysql db and the live Mysql db username, password, and db name matches, so i don't have to change it.

Both websites are located on the root folder, so i don't have to change the ps_base value neither.

  • Log in to your Back Office, go to the "Preferences" tab, select the "SEO & URLs" sub-tab, and change the domain name to your new domain. Do the same for the SSL domain.
    In effect, this will update the "PS_SHOP_DOMAIN" and "PS_SHOP_DOMAIN_SSL" rows in the "ps_configuration" SQL table.
  • In your back-office, go to the "Tools" tab, "Generators" sub-tab, and regenerate both the .htaccess and robots.txt files.

This is where problems start. I can't log into the Back Office (username/password seems wrong), and as mentioned earlier, a module seems to not work on front page, however, the entire website works like the live one exept for those two problems.

 

I hope this will give you a better idea of what's going on.

 

Best regards.

Edited by clad0 (see edit history)
Link to comment
Share on other sites

Hi clad0,

Looking back over your original post, I see that you say that the login info you use on the Front Office isn't working in the Back Office. This is normal behavior, as the admin login information is completely separate from anything in the Front Office. You may want to make sure that you've been provided with the correct Back Office login credentials.

 

If they are correct but still not working, you may want to check out this great external guide to resetting your password through the database.

 

I hope this helps.

 

-Mike

Link to comment
Share on other sites

Hello Mike Kranzler,

 

Following your guide allowed me to reset the password to what it's supposed to be on the live website.

 

However, the resulting password hash remains the same as before, thus confirming I was using the good password, and username.

 

And yes, I have the backoffice username and password working on the live website.

 

I've come to think the problem may come from the fact the live website and me are not using the same versions of mysql and/or php.

 

Could this be the cause of my problem?

Edited by clad0 (see edit history)
Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...