maio Posted December 18, 2013 Share Posted December 18, 2013 (edited) since I started out my first presta-shop many versions have been released, usually the best solution, for avoiding to get stuck while upgrading, is creating a test site where to try out the new version, once you're ready then you'll transfer your new shop on live environment_ and so what's the best practice for transferring a shop ?? step 1. (getting ready - backing up everything...) backup your database, the database is where most of your site's information is stored (it's one of the most precious elements // you absolutely don't want to mess it up) you can complete this step either using ssh-connection (with a tool such as putty or SSH-client) or using PHPmyadmin with ssh connection type in the following command mysqldump -p -u user-name database-name > db-backup-name.sql this will prompt your database's user password and then you'll find your db-backup-name.sql in your server's root, ----- with phpmadmin got to the database you want to export, use export in the menu choose custom select all tables select structure+data select "insert" function for dumping data in either ways you should have copied the database ----- after the database you should also backup your old directory , just in case your transfer doesn't work, step2. (importing database in my sql) now you have to import your new shop's database (that you have previously backed up) in mysql . since I've had problems with phpimport-function i'll just describe the procedure with a SSH connection (which is much more reliable..) --with my-sql cpanel create a database (new_database_name) then type in this command to import new database mysql -p -u username new_database_name < backed-up-file.sql I suggest you use your root user, after this you'll assign this database to a specific user through mysql/cpanel (it's better for security reasons) step 3 (directory files) copy your test-directory in order for it to become your live site, (you've previously backed up the old site so it should be safe) type this in shell cp -a test/. live-site-dir/ you should have copied your test shop in live-shop position step 4 (important) before doing anything else modify your setting.inc.php file (config folder) in order for it to point to new database change: define('_DB_NAME_', '.......'); define('_DB_USER_', '................'); define('_DB_PASSWD_', '.....................................'); at last ,with phpmyadmin, go to shop_url table and modify it to point to proper dir... clearly after all these url-changes you need to regenerate htaccess, (turn on/off freindly urls) ----- that should be it, let me know, best regards Edited December 30, 2013 by maio (see edit history) Link to comment Share on other sites More sharing options...
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now