Need help buying now? +48-22-219-5163 +1-917-720-3250
My Cart

Your Cart is Empty

Need help buying now?
+48-22-219-5163 +1-917-720-3250

Magento Installations

Magento Installations

Magento is a very smart eCommerce platform. It is installed only in a particular order configured in the settings and it is installed with a special algorithm. We suggest to consider how to do the Magento installation for several stores, what you need for it and what the advantages of this method are.

Why is it an advantage to have several Magento stores?

If you have the majority of the platforms, which are filled in with the products regularly, you need to control their work, condition, add customers, etc. You spend much time on checking different platforms and the creation of several stores on the same Magento Installation is formed firstly for the administrator’s comfort (owner’s comfort) and content manager’s comfort.

Some Moments

You should be informed that this action can be done if only you have some Magento work experience. Also you should have at least one store. If you have everything of this, you should do some procedures or contact specialists in order to do them. For instance, you can contact GoMage company or other Magento experts.

How you can add a Magento store

Website - this is the site which will be connected with the store;
Store – this is the store which will be created on the site platform;
Store View – respectively, it is a copy of the store (usually it is used for the internationalization).

First of all, you should indicate where this store will be located. You should go to the admin panel and create new directories on the path System - Manage Stores. There should be the folders Store, Store View and Website created. Let’s investigate it properly:

Website:
The title is Shoes
The label is shoes

Store:
The title is Main Store
You should choose the label from the list called Website Shoes
Now you should go to the Root Category in the dropdown menu and choose a new root directory which has been created above.

Store View:
You should go to Main tore from the Store section.
The title is English (you can name it as you want)
The label is shoes_en
You should set the status up as Enabled

The other stores which need to be created on the same Magento Installation should be written the same way.

Then you should indicate new URL addresses for the created store. You need to go to the admin panel: System – Configuration. You will find the Configuration Scope in the upper corner and you need to change Default Config to the label of the Website directory. In our case it is “shoes”. Now you should indicate the path to Base URL in the sections called Web, Secure and Unsecure.

Remember that you need to indicate a new address for every section, otherwise Magento will redirect the customers to the same pages and it will influence on the customers’ trust and attitude to the store. Also, you should check whether the end of every URL has the necessary closing sign “/” In order to make all the written addresses active you need to do the following:

The Magento store should be located in the subdirectory to which the path (URL) indicates. This directory is located in the root folder of a Magento site. It is the most widespread action, but not necessary.

In order to upload all the files you should use the FTP connection, create a folder in the root section. It will be shoes folder in our case. Some files from the root should be copied to this folder: index.php and htaccess. As soon as you do it, you need to save the changes and open the file idex.php for editing. You will find the line $mageFilename = 'app/Mage.php' there. Our task is to change the path to the correct one, in other words, to write all the folders completely. Also you need to write two additional parameters - Mage::run(). After the editions the code should have the following view: Mage::run('shoes', 'website').

Domain Names

Of course, your stores should have the different names, in other words, you need to change the domains. You need to write the following information for each of them in the already fixed index.php file:

Instead of Mage::run();
switch($_SERVER['HTTP_HOST']) {
       	case 'shoes.com':
       	case 'www.shoes.com':
       	Mage::run('shoes', 'website');
       	break;
       	default:
       	Mage::run();
       	break;
}

 

If there are a big number of stores you should change the code in the following way:

switch($_SERVER['HTTP_HOST']) {
       	// the domain address
       	case 'the domain address ':
       	case 'the domain address ':
       	Mage::run('shoes', 'website');
       	break;
       	
       	// the domain address2
       	case 'the domain address2':
       	case  'the domain address2’:
       	Mage::run('hats', 'website');
       	break;
       	
       	// the domain address3(default store)
       	default:
       	Mage::run();
       	break;
}

 

After this action the created store will be accessible with a new address.

There is another way to update the settings quickly. You need to go to the file httpd.conf. You can find it on the path /var/www in the folder http. Then you should open it using the code editor:

<VirtualHost *:80>
	ServerAdmin webmaster@domain1.com
	DocumentRoot /var/www/http
	ServerName domain 1
</VirtualHost>
<VirtualHost *:80>
	ServerAdmin webmaster@domain2.com
	DocumentRoot /var/www/http
	ServerName domain 2
</VirtualHost>
<VirtualHost *:80>
	ServerAdmin webmaster@domain3.com
	DocumentRoot /var/www/http
	ServerName domain 3
</VirtualHost>

 

Then you should edit the file .htaccess, which can be found on the path at /var/www/http/.htaccess

SetEnvIf Host www\. domain 1\.com MAGE_RUN_CODE= domain 1_com
SetEnvIf Host www\. domain 1\.com MAGE_RUN_TYPE=website
SetEnvIf Host ^ domain 1\.com MAGE_RUN_CODE= domain 1_com
SetEnvIf Host ^ domain 1\.com MAGE_RUN_TYPE=website
SetEnvIf Host www\. domain 2\.com MAGE_RUN_CODE= domain 2_com
SetEnvIf Host www\. domain 2\.com MAGE_RUN_TYPE=website
SetEnvIf Host ^ domain 2\.com MAGE_RUN_CODE= domain 2_com
SetEnvIf Host ^ domain 2\.com MAGE_RUN_TYPE=website
SetEnvIf Host www\. domain 3\.com MAGE_RUN_CODE= domain 3_com
SetEnvIf Host www\. domain 3\.com MAGE_RUN_TYPE=website
SetEnvIf Host ^ domain 3\.com MAGE_RUN_CODE= domain 3_com
SetEnvIf Host ^ domain 3\.com MAGE_RUN_TYPE=website  
  

 

The recipe of the code has been taken from the site www.magentocommerce.com

Extensions for Magento stores

Now we should consider the extensions for every Magento store. Many Magento owners are afraid of creating several stores on the same Magento Installation because they think that every additional extension will demand a separate license for each of these Magento stores. For instance, GoMage company provides you with the opportunity to buy the extension license and if you have several stores on the same Magento Installation, you need only to buy the extra domains option. This option will activate the extension for several stores that are on the same Magento Installation. So, you see that some Magento extensions have the opportunity to be activated for several sites on the same Magento Installation.

It is easy to do during the activation process. The license sees the quantity of your Magento stores and allows you ticking the appropriate check boxes that are opposite to the necessary sites.

If you have any questions as to this option, you can contact our GoMage specialists and we will answer you as soon as possible.

Newsletter