Host Site Matching

Author Message

Deane Barker

Wednesday 10 November 2004 1:00:46 pm

I have ez 3.4.4 located in a central directory, and I need to be able to map several sites to it. Here is my understanding:

If I do this in /setting/site.ini...

[SiteAccessSettings]
MatchOrder=host
HostMatchType=map
HostMatchMapItems[]=domain1.net;domain1
HostMatchMapItems[]=domain2.net;domain2

Then, inbound requests to domain1.net will look to the file in...

/setting/siteaccess/domain1/site.ini.append.php

...for database connection information and other settings. All settings in that file will override matching settings in /setting/site.ini. Is this right?

Do I need to disable all other match orders? I don't want to use URI or Post -- just domain will be find.

Related to this, how do you initialize a new database? Every other time I've set up ez, I've gone through the wizard. If I used the wizard to set up domain1, and now I need to set up domain2, how do I get the right tables and such in the domain2 database? I have looked for a SQL file, but I haven't found one.

Finally, do the DebugAccess and DebugExtraAccess directives work? I have set them, but I get nothing new on the screen when I attempt to access the site.

Deane

Deane Barker

Wednesday 10 November 2004 1:42:29 pm

Through some hacking and debugging of the access.php file, I found the (a?) problem -- the site is TOTALLY ignoring "settings/site.ini"

For instance, I have this in site.ini:

MatchOrder=host

However, when the access.php code pulls that setting, it gets "uri" as the value. Why would this be?

Deane

Deane Barker

Wednesday 10 November 2004 1:53:17 pm

I've confirmed this. If I hack this into the access.php file...

$order = array('host');
(then, further down...)
$matchMapItems[] = array("domain1.com","domain1");
$matchMapItems[] = array("admin.domain1.com","domain1_admin");
$matchMapItems[] = array("domain2.com","domain2");
$matchMapItems[] = array("admin.domain2.com","domain2_admin");

..then it works exactly as it should. It is not getting these settings from the site.ini file for some reason. Why would this be?

Also, now that I've got it talking to a different database, I still need to figure out how to initialize that database.

Deane

Deane Barker

Wednesday 10 November 2004 2:25:11 pm

Found the database file -- forget that. I'm moving this to a new thread since the core problem has nothing to do with host matching, but instead has to do with the install refusing to read site.ini.

Deane

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