Multi doman website

Author Message

David Lafonte

Friday 20 June 2008 9:15:58 pm

Hello there
I try to find help on forum but so far I was not lucky
Here is my plan
I have hosting where I can have unlimited domains
My main domain like www.mydomain.com
But I can have like I said unlimited domain
I would like to setup few more domain using single installation and single database of ez publisher
Like
www.mydomain.com
www.mydomain1.com
www.mydomain2.com
Basically my main domain is located in /home/mydomain.com/public_html/
That is folder of www.mydomain.com
My other domains are in

/home/mydomain.com/public_html/mydomain1.com www.mydomain1.com

/home/mydomain.com/public_html/ mydomain2.com www.mydomain2.com

/home/mydomain.com/public_html/ mydomain3.com www.mydomain3.com
Any idea how I can setup this
So if I enter example
www.mydomain2.com go to www.mydomain2.com using installation single installation ez publish
Any idea, suggestion please
Thanks

Greg McAvoy-Jensen

Friday 20 June 2008 9:41:27 pm

I wouldn't set up new directories for each new domain (for example, /home/mydomain.com/public_html/mydomain1.com). Everything should point to index.html in the root eZ Publish directory; let eZ Publish figure things out from there.

The way to differentiate multiple domains on one eZ Publish installation is to use a separate "siteaccess" for each domain. So in settings/siteaccess, add an additional directory for each site access; in each directory, put a site.ini.append.php tailored to that particular domain. It will give you the flexibility to decide whether they all use the same database and var directory.

In settings/override/site.ini.append.php, be sure each of your new siteaccesses is recognized. Also, this is where you specify which domain corresponds to which siteaccess--by use of the MatchOrder directive. If you happen to name each site access the same as the domain (without the www.), then your configuration would look like this:

[SiteAccessSettings]
MatchOrder=host
HostMatchType=map
HostMatchMapItems[]=www.mydomain.com; mydomain
HostMatchMapItems[]=www.mydomain1.com; mydomain1
HostMatchMapItems[]=www.mydomain2.com; mydomain2

Of course, you'll need to also include the admin interface.

You can read more at http://ez.no/doc/ez_publish/technical_manual/4_0/concepts_and_basics/configuration/access_methods.

Granite Horizon, Certified Developer of eZ Publish Web Solutions
Provider of the SaaS Solution Granite Horizon In The Cloud | http://granitehorizon.com/cloud
http://granitehorizon.com | +1 916 647 6350 | California USA | @granitegreg
Blog: http://granitehorizon.com/blog

David Lafonte

Saturday 21 June 2008 9:02:30 am

So if I enter my domain www.mydomain.com.
Do I need do some web host setup?
Like apache conf file

Greg McAvoy-Jensen

Saturday 21 June 2008 9:29:57 am

You'd just need one virtual host setup for the whole set--just include something like (I'm using Apache 2):

DocumentRoot /home/mydomain.com/public_html/
    ServerName www.mydomain.com
    ServerAlias www.mydomain1.com
    ServerAlias www.mydomain2.com

Granite Horizon, Certified Developer of eZ Publish Web Solutions
Provider of the SaaS Solution Granite Horizon In The Cloud | http://granitehorizon.com/cloud
http://granitehorizon.com | +1 916 647 6350 | California USA | @granitegreg
Blog: http://granitehorizon.com/blog

David Lafonte

Saturday 21 June 2008 10:02:15 am

Thanks for reply
I do not have access to apache conf because i am on shared hosting
can i do something simillar in .htaccess
Thanks

Donat Fritschy

Monday 23 June 2008 9:55:57 am

Your hosting provider will most certainly define the ServerAlias directive for you.

Alternatively, you can stick with the different site roots and put this directive into the .htaccess file

Redirect / http://www.example.com/ 

http://www.webmanufaktur.ch - Developers united in eZ Publish: http://www.cjw-network.com

Powered by eZ Publish™ CMS Open Source Web Content Management. Copyright © 1999-2014 eZ Systems AS (except where otherwise noted). All rights reserved.