Magento Multi-domain multi-store

Source: Internet
Author: User

Pre-guidance

We are using parked domain to point to your existing magento file root directory for the domain name you want to add.

As mentioned in the preview, we have a Magento station domain name for one. com , add a new domain name two.com. Set the root directory of the two.com to the root directory of one.com.

This article is based on the magento1.2 version, and other versions are shown at the end of this article.

Practice

We assume that your magento original domain name is one.com , want to implement Magento multi-store domain name is two.com. First you install the one.com magento website, and then refer to the following tutorials.

1.Magento settings to be done in the background

Step one: go backstage catalog->manage catagories adds a new root category for the store to add two (names can be taken casually) as

Magento Multi-domain multi-store Figure 1

Step Two: enter system->manage Stores add a new website for the store to be added, click the Create website button. , fill in the contents such as, note fill in the code in the next step need to use

Magento Multi-domain multi-store Figure 2

Then save, click Create Store,add a store for the newly added website ,

Magento Multi-domain multi-store Figure 3

Website is just created, and theroot category is created in the first step.

Then save, click Create store View, fill in the relevant information, such as

Magento Multi-domain multi-store Figure 4

Name,code you write a good distinction, easy to remember ,Status Select enabled(activate) Click Save

Step three into system->configuration

In the setting range option on the left, select the store under our new shop and set the

Magento Multi-domain multi-store Figure 5

Our new store name in the above step is website, we select the website, and then select

Web settings in the left column , such as

Magento Multi-domain multi-store Figure 6

Remove all settings after the check, do not use the default settings, in the unsecure base URL to fill in your multi-store URL, in this case is two.com, note Fill in the full domain name: http://www.two.com , Don't miss the last slash of the domain name.

Secure is an encrypted URL, and if you do not use SSL, Please also fill in the Http://www.two.com. Last saved

Summarize

What you need to set up in this Magento is gone. In the magento background Settings We will use in the next step is the second step of create website when the code: two .

2. modify the root directory index. php file

Open The Magento Web site root directory, edit the file index.php

Will

Mage::run();

Replaced by

switch ( $_SERVER [ ‘HTTP_HOST‘ ]) { case ‘two.com‘ : case ‘www.two.com‘ : Mage::run( ‘two‘ , ‘website‘ ); break ; default : Mage::run(); break ; }

If you want to add more domain names, repeat as above steps

At this point, the setup is complete and can be accessed using two.com

Recently someone has reflected such as on the steps after the website cannot run, do not panic, such as the article is before for Magento version 1.2 applicable, the other version is not. New Magento version See Http://www.magentocommerce.com/wiki/multi-store_set_up/multiple-website-setup or Google under "Magento Multiple websites "

Reprint marked Source: Hellokeykey.com Right Pocket key

Magento Multi-domain multi-store

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.