Magento multistore setup under Plesk
Please note there is an easier way which may suite your setup better: http://dx3webs.com/front/2011/09/create-a-multi-store-setup-in-magento/
Magetno is a very powerful and flexible e-commerce platform which can allow a single installation of the platform to support multiple sites on multiple domains, sub-domain or folders.
This tutorial assumes you have a linux based Plesk server with SSH access and that each store will be on a seperate domain.
If you host with Dx3webs we will setup this up for you for a one off fee of £25.
There is already a very good tutorial for setting this up under cpanel but the procedure is slightly different for Plesk.
Follow the instruction given on crucial’s tutorial till you get to step 20.. then come back here
Assume that your main store is here
/var/www/vhosts/domain1.com/httpdocs/
step 1
Create domain2.com as your normally would in plesk.
Step 2
Create vhost.conf in /var/www/vhosts/domain2.com/conf and enter
<Directory /var/www/vhosts/domain2.com/httpdocs> php_admin_value open_basedir "/var/www/vhosts/domain1.com/httpdocs:/var/www/vhosts/domain2.com/httpdocs:/tmp" </Directory>
this will allow the two shops to call files which would other wise not be allowed.
If you are using ssl you will need to copy vhost.conf to vhost_ssl.conf in the same folder.
To make these change ‘live’ run the following
/usr/local/psa/admin/sbin/websrvmng -v -a
Step 3
Copy index.php and .htaccess from /var/www/vhosts/domain1.com/httpdocs to /var/www/vhosts/domain1.com/httpdocs
if you have installed magento in its own folder copy the files from:
/var/www/vhosts/domain1.com/httpdocs/magento to /var/www/vhosts/domain1.com/httpdocs/magento
on domain2.com edit index.php
Find
$mageFilename = '/app/Mage.php';
and change to
$mageFilename = '/var/www/vhosts/domain1.com/httpdocs/shop/app/Mage.php';
This is why you needed to change vhost.conf in step 2 so that domain2 can talk across site to domain2
Now find
Mage::run();
and change to
Mage::run('site2','website');
where ‘site2′ is the code you assigned in Step 8 of the crucial tutorial
Stpe 4
You now need to create symbolic link to key folder on domain1.com
run the following while in /var/www/vhosts/domain2.com/httpdocs/
ln -s /var/www/vhosts/domain1.com/httpdocs/404/ ./404 ln -s /var/www/vhosts/domain1.com/httpdocs/app/ ./app ln -s /var/www/vhosts/domain1.com/httpdocs/includes/ ./includes ln -s /var/www/vhosts/domain1.com/httpdocs/js/ ./js ln -s /var/www/vhosts/domain1.com/httpdocs/media/ ./media ln -s /var/www/vhosts/domain1.com/httpdocs/report ./report ln -s /var/www/vhosts/domain1.com/httpdocs/skin/ ./skin ln -s /var/www/vhosts/domain1.com/httpdocs/var ./var
This will redirect all calls to the domains on domain2.com to the correct place on domain1.com
Note: if you installed on domain1.com/magento all you need to do is to create a symbolic link to :
ln -s /var/www/vhosts/domain1.com/httpdocs/magento ./magento
Rock solid speed and reliability
Robust, reliable, fully backed up, secure UK based Magento hosting for £175 per year. Full details here or Contact us
Related posts:

Thank you very much !!!!!!!!!!