ExpressionEngine CMS
Open, Free, Amazing

Thread

This is an archived forum and the content is probably no longer relevant, but is provided here for posterity.

The active forums are here.

Help! Domain1 SITE URL keeps rendering the CP Home in an MSM vers. 2.1 configuration!**

September 06, 2011 9:03pm

Subscribe [6]
  • #1 / Sep 06, 2011 9:03pm

    digigumball

    37 posts

    Hi All,

    I have a paths or URL problem with the default_site demo install.  I’m able to log into CP just fine, toggle through the 3 sites I created, and have opted for the single admin install for all 3 sites (Site A, B & C), however at one time I was able to see the default demo site at domain1.com, but since arranging the directory structure as described in the user guide for ee 2.x, when I select Site in CP for domain1.com, I get the error message:

    Not Found “The requested URL /index.php was not found on this server.”

    If I change the root directory of the site to the sub-directory (domain1.com/sub-domain/) the index.php & admin.php is located in then I get the CP window, not the default site..strange.  😖

    I know the paths to both the root directory of the site, and to the system folder, The domain1.com URL is pointing to the webserver as expected, so my general config is set right. My index.php file is using a relative system path, but I’m still missing a critical setting to have domain1.com point to the index.php and find the default site there…

    I hope I explained this clearly enough…I really need to have someone PM me and look at the sites directly… 😉

    please help!

  • #2 / Sep 07, 2011 11:26am

    Sue Crocker

    26054 posts

    Hi, digigumball.

    Let’s start out with having you describe how you’ve set up your sites.

    You have domain1.com, domain2.com, and domain3.com? How are they related? Are domain2 and domain3 subfolders off the main site?

    What changes did you make to the admin.php and index.php for each site?

    It might be faster to look around, but let’s take a few minutes to get this info first.

  • #3 / Sep 07, 2011 11:58am

    digigumball

    37 posts

    Hi Sue!

    All the domains are separate sites, no subdomains yet, and I want to have one CP login for all three sites, so structure so far is:

    Library/Webserver/Documents (root directory),  this is the path to domain1.com:

    └── domain1
      ├── admin.php
      ├── index.php
      ├── images
      ├── system
      └── themes
    └── domain2
      └── index.php
    └── domain3
      └── index.php

    Index.php only changed & uncommented variables are:  (copied into both domain1 & 2 folders)

                $system_path = ‘./system’ ;

    AND MSM variables

    $assign_to_config[‘site_name’]  = ‘default_site’;
    $assign_to_config[‘cp_url’] = ‘http://domain1.com/domain1/admin.php’;
    $assign_to_config[‘site_url’] = ‘http://domain1.com’;

    $assign_to_config[‘site_name’]  = ‘domain2_shortname’;
    $assign_to_config[‘cp_url’] = ‘http://domain1.com/domain1/admin.php’;
    $assign_to_config[‘site_url’] = ‘http://domain2.com’;

    Only one admin.php file exists in the domain1 folder, none in domain2 or 3 as I want a single CP login for all 3 domain/sites.

    admin.php only changed & uncommented variables are:  (copied into both domain1 & 2 folders)

                $system_path = ‘./system’ ;

    AND MSM variables

      $assign_to_config[‘site_name’]  = ‘default_site’;
      $assign_to_config[‘cp_url’] = ‘http://domain1.com/domain1/admin.php’;
     
      $assign_to_config[‘site_name’]  = ‘domain2_shortname’;
      $assign_to_config[‘cp_url’] = ‘http://domain1.com/domain1/admin.php’‘;
     
      $assign_to_config[‘site_name’]  = ‘domain3_shortname’;
      $assign_to_config[‘cp_url’] = ‘http://domain1.com/domain1/admin.php’‘;

    Please note: domain1 (without “.com) is the name of the domain1 folder the has the system as sub-folder

  • #4 / Sep 07, 2011 12:23pm

    Sue Crocker

    26054 posts

    This looks similar to how I have things set up in my MediaTemple domains. However I do have the ability to login to any of the three sites using an admin.php in each folder.

    Is there a a reason you don’t want this functionality?

  • #5 / Sep 07, 2011 12:31pm

    digigumball

    37 posts

    Mainly, because I’m the sole owner/admin for all the sites and workflow is easier with a single login, and toggling between sites inside CP.

    Also, I’m building all sites from the ground-up around the same time, less jumping between them.  Please note that all sites are being hosted on a local server, so no FTP either.  Any thoughts about my initial problem?

    If you go to http://www.undercurrentlabs.com, you’ll see my problem - I’ve made the site live temporarily 🙄

  • #6 / Sep 07, 2011 10:04pm

    digigumball

    37 posts

    help…anyone?

  • #7 / Sep 08, 2011 11:55pm

    Dan Decker

    7338 posts

    digigumball,

    Let me see if I can offer some assistance. In you index.php files for your second an third sites, does it aleviate your issue if you set:

    $system_path = ‘./domain1/system’ ;

    And are these values being set in the *same* admin.php:

    $assign_to_config[‘site_name’]  = ‘default_site’;
      $assign_to_config[‘cp_url’] = ‘http://domain1.com/domain1/admin.php’;
      
      $assign_to_config[‘site_name’]  = ‘domain2_shortname’;
      $assign_to_config[‘cp_url’] = ‘http://domain1.com/domain1/admin.php’‘;
      
      $assign_to_config[‘site_name’]  = ‘domain3_shortname’;
      $assign_to_config[‘cp_url’] = ‘http://domain1.com/domain1/admin.php’‘;

    If that’s the case, I would think they are overwriting each other. Essentially only the *last* value would be assigned. I’m not sure that what you are trying to achieve ( a *master* CP login location) is supported. But, there is nothing preventing you form managing all of your sites from the 1 login location. The MSM menu in the upper right of the CP allows for you to switch between sites on the fly.

    If you set up MSM according to the installation instructions, do your issues go away?

    Cheers,

  • #8 / Sep 09, 2011 1:05am

    digigumball

    37 posts

    Hi Dan,

    Thank you so much for responding to my post, as I have been stuck troubleshooting this on my own since I posted!  :ahhh:

    I did change the index.php files for domains 2 & 3, and additionally uncommented the admin.php code below, with no effect!

    And are these values being set in the *same* admin.php:

    $assign_to_config[‘site_name’]  = ‘default_site’;
      $assign_to_config[‘cp_url’] = ‘http://domain1.com/domain1/admin.php’;
      
      $assign_to_config[‘site_name’]  = ‘domain2_shortname’;
      $assign_to_config[‘cp_url’] = ‘http://domain1.com/domain1/admin.php’‘;
      
      $assign_to_config[‘site_name’]  = ‘domain3_shortname’;
      $assign_to_config[‘cp_url’] = ‘http://domain1.com/domain1/admin.php’‘;

    As far as switching between sites, I was able to switch between them fine, until yesterday when it became stuck on domain2, but I have not been able to chase-down what I did to prevent switching.

    Also, if you go to http://www.undercurrentlabs.com, you can temporarily see the live site which points to the root directory, one directory up from the domain1 directory where the index.php file is…if that provides any clues…

  • #9 / Sep 09, 2011 1:21am

    digigumball

    37 posts

    Oh forgot,

    I did set up MSM according to the installation instructions, including the directory structure for all the domains, except for the suggestion to only have one admin.php for the single login for all 3 sites.  Current structure:

    Library/Webserver/Documents (root directory),  this is the path to domain1.com:

    └── domain1
      ├── admin.php
      ├── index.php
      ├── images
      ├── system
      └── themes
    └── domain2
      └── index.php
    └── domain3
      └── index.php

    Index.php only changed & uncommented variables are:  (copied into both domain1 & 2 folders)

  • #10 / Sep 09, 2011 1:41am

    LMO

    203 posts

    So your problem is when you are in the CP some of the sites wont work when switching between them?
    Are you using the domain.com/admin.php link or the domain.com/system link to access the CP?

  • #11 / Sep 09, 2011 2:00am

    digigumball

    37 posts

    Here’s the login url that is used to login to CP:

    http://domain1.com/domain1/index.php?S=0&D=cp&C=login

  • #12 / Sep 09, 2011 2:44am

    digigumball

    37 posts

    Here’s a clue I just discovered:

    In Index.php, I re-commented the cp_url MSM variable for domain2 which caused an error on the server keeping the CP logon from displaying which leads me to believe that something is wrong with the cp_url for domain1…I may be drawing a premature conclusion, but I thought I’d let you know hat I’m seeing… if I uncommnet the same cp_url line code the CP login comes back.  Question, since this variable is the same for domain one and uncommented, why is the CP logon effected still?

      $assign_to_config[‘site_name’]  = ‘domain2_shortname’;
    * $assign_to_config[‘cp_url’] = ‘http://domain1.com/domain1/admin.php’;
      $assign_to_config[‘site_url’] = ‘http://domain2.com’;

  • #13 / Sep 09, 2011 8:33am

    LMO

    203 posts

    The CP url should be the exact url used when login into the CP so it should match your previous post using index.php. Also I believe you only need 1 set of the assign_to_config variables to match your default site.

  • #14 / Sep 09, 2011 11:12am

    digigumball

    37 posts

    The CP url should be the exact url used when login into the CP so it should match your previous post using index.php. Also I believe you only need 1 set of the assign_to_config variables to match your default site.

    Agreed, the URLs do match, and I have now eliminated the additional MSM assign_to_config variables that the EE user documents suggested for MSM, and can now switch between sites in CP….a big thank you on that advice!  😊

    All though my original problem still remains that I can not see the demo “band” install, and domain1 actually shows the CP login page now!!   I just can’t get this right.  I am missing some fundamental understanding on MSM set-up!!  :ahhh:

    I’m looking for more complete documentation or examples that would give me the anatomy or fundamentals to a multi-site approach with EE 2.2/MSM 2.1 other than what I see here

  • #15 / Sep 09, 2011 11:28am

    LMO

    203 posts

    It sounds as if you might have saved your admin.php file over your index.php. You may need to grab a new index.php file from default install files.

.(JavaScript must be enabled to view this email address)

ExpressionEngine News!

#eecms, #events, #releases