Jump to content

Trouble with MultiSite on Localhost


FrancisChung
 Share

Recommended Posts

Hi there,

I'm trying to set up different instances of our website so I thought I'd try it out locally first before deploying out to the real world.

I'm interested in a multi-site/independent DB setup so I'm following the instructions (Step1 Alternative)  in https://processwire.com/api/modules/multi-site-support/

The steps I've taken are :

1) I've copied my /site folder to /site-dev.

2) Modified index.config.php and moved it to the webroot

3) Modified config.php in site-dev and changed the DB credentials.

I thought this was all the steps I needed to take but it didn't work.

I've also added an entry in /private/etc/hosts for dev.localhost to point to 127.0.0.1

Is there something else I have overlooked?

Thanks in advance!

------------------

index.config.php
function ProcessWireHostSiteConfig() {
 
        return array(
 
                /*
                 * Some Examples (you should remove/replace them if used).
* Just note that the values must begin with 'site-'.
                 *
                 */
                 'dev.localhost' => 'site-dev',
 
/*
* Default for all others (typically /site/)
*
*/
'*' => 'site',
 
                );
 
}
 
config.php
$config->dbHost = 'localhost'; 
$config->dbName = 'SSS-Live';
 

post-3661-0-45662100-1444811906_thumb.pn

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

×
×
  • Create New...