How do I transfer a local Magento install onto my live server?

后端 未结 10 1917
别跟我提以往
别跟我提以往 2020-12-07 14:58

Uploading a Magento install

I have spent a long time building a store with Magento on my local development PC.

相关标签:
10条回答
  • 2020-12-07 15:34

    I recently moved a full Magento install complete with a couple of extensions. I found it as simple as copying the directory structure, changing the BASE_URL in config_data and changing the database info in 'local.xml'.

    0 讨论(0)
  • 2020-12-07 15:35

    I follow this tutorial http://magentoexplorer.com/how-to-move-or-transfer-magento-from-localhost-to-live-server and succeeded to move my Magento installation from Localhost (XAMPP) to live server. Simply, you can follow these 5 steps:

    1. Export database of Magento site (SQL file)

    Open PHPmyadmin to export your database to SQL file or you can run this command from SSH mysqldump -uUSERNAME -pPASSWORD DATABASE > backup.sql

    2. Upload code of Magento site to live server

    Upload all files/folder from your localhost to live site using FTP client, you can zip and unzip file to make sure all files are preserved

    3. Import database to live server and change database configuration.

    Again, use PHPmyadmin to import the .sql file we export in step 1 or run this command from SSH mysql -uUSERNAME -pPASSWORD DATABASE < backup.sql

    4. Replace local URL with live site URL in database

    Find the table core_config_data and edit url in column web/unsecure/base_url and web/secure/base_url to the domain of your live site

    5. Pointing your domain to server’s IP

    Hope this helps

    0 讨论(0)
  • 2020-12-07 15:36

    Don't change core files, instead either overload them via custom modules or, if absolutely necessary, replicate them in the app/local folder, which ensures that the modified versions get loaded instead of the standard files.
    Deployment is handled like this:
    I keep all Magento source files under version control, Subversion specifically. When I've tested my changes, I just submit them to the Subversion server and then export (or update) them on the production server. That way, I don't need to upload the whole site again, only the changed files get updated. Using the auto-installing extensions mechanism ensures that extensions are installed on the production server as they were on the development server. The only thing that's needed now is to adjust database settings for the new extensions on the production server (something that can also be handled by the extensions mechanism).

    0 讨论(0)
  • 2020-12-07 15:38

    Its very easy to do, i did it and i made a document of it. all you have to do is add these lines in your sql file.

    Place these lines of SQL code on very top of the .sql file: 
    SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT;
    SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS;
    SET @OLD_COLLATION_CONNECTION=@@COLLATION_CONNECTION;
    SET NAMES utf8;
    SET @OLD_UNIQUE_CHECKS=@@UNIQUE_CHECKS, UNIQUE_CHECKS=0;
    SET @OLD_FOREIGN_KEY_CHECKS=@@FOREIGN_KEY_CHECKS, FOREIGN_KEY_CHECKS=0;
    SET @OLD_SQL_MODE=@@SQL_MODE, SQL_MODE='NO_AUTO_VALUE_ON_ZERO';
    SET @OLD_SQL_NOTES=@@SQL_NOTES, SQL_NOTES=0;
    Place these lines of SQL code on very end of the .sql file: 
    SET SQL_MODE=@OLD_SQL_MODE;
    SET FOREIGN_KEY_CHECKS=@OLD_FOREIGN_KEY_CHECKS;
    SET UNIQUE_CHECKS=@OLD_UNIQUE_CHECKS;
    SET CHARACTER_SET_CLIENT=@OLD_CHARACTER_SET_CLIENT;
    SET CHARACTER_SET_RESULTS=@OLD_CHARACTER_SET_RESULTS;
    SET COLLATION_CONNECTION=@OLD_COLLATION_CONNECTION;
    SET SQL_NOTES=@OLD_SQL_NOTES;
    

    for more details

    http://findgodaddyhostingreview.com/2010/06/how-to-move-magento-from-production-to-live-server/

    0 讨论(0)
提交回复
热议问题