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.

msm + htaccess for 2 domains

March 08, 2012 1:29pm

Subscribe [2]
  • #1 / Mar 08, 2012 1:29pm

    Amanda

    54 posts

    I’m working on a project that uses the multi site manager.  The “main site” is already live.  I’m trying to get a 2nd site working on the dev environment.

    Unfortunately, the server guy (who initially installed ee and msm) didn’t follow the User Guild instructions (http://ellislab.com/expressionengine/user-guide/cp/sites/domainsetup.html) and instead it’s set up:
    └── domain1.com
      ├── admin.php
      └── domain2.com
          ├── admin.php
          └── index.php
      ├── index.php
      ├── images
      ├── system
      └── themes

    Now he’s got domain1.com AND domain2.com going to the root directory (so domain1.com) and he thinks I should be able to redirect domain2.com using the htaccess file.  The problem is that I’ve got the rewrites to remove index.php for domain1.com and it’s messing up.

    I’ve tried to add code found here http://support.lunarpages.com/knowledge_bases/article/549 to redirect domain2.com to the subdirectory and it works for the home page and images (for some reason) but doesn’t work for files (phpinfo.php for testing and any js).

    Any other internal ee links don’t work (ie domain2.com/test/) and often they show the home page for domain1.com (ie domain2.com/index.php/test/).

    The “real” url displays a template properly (ie domain1.com/domain2.com/test/).

    Is there a way to do with with htaccess?  Is it possible to just have domain2.com point directly at the subdirectory?

    Any help is much appreciated!
    Thanks
    Amanda

  • #2 / Mar 09, 2012 10:32am

    pushloop

    422 posts

    Hey Amanda

    I’m having issues with a very similar setup which I’m currently trying to resolve.
    Basically, just like you I managed to redirect the site, pages and images, but I’m having some serious issues with my index.php as you can see in my posts below.

    At the moment I’ve gone back a step to rethink this, and have posted about the issues here:

    http://ellislab.com/forums/viewthread/212817/
    http://ellislab.com/forums/viewthread/212831/

    I’ll let you know if I make any progress!

  • #3 / Mar 11, 2012 5:40am

    pushloop

    422 posts

    Hey Amanda.

    Just thought I’d let you know that I was able to sort out the issues yesterday. I’ve tried to explain in each of the two threads I’ve posted above!

    The quick answer to your question about pointing the domain directly to a sub folder is YES - that was basically the solution to the problems we were experiencing with our setup.

    Let me know if there’s anything else I can do to help 😊


    /André

  • #4 / Mar 13, 2012 1:34am

    Amanda

    54 posts

    Thanks for your help André.  Your solution is what the server guys ended up doing as well.

  • #5 / Mar 13, 2012 4:52am

    pushloop

    422 posts

    I’m glad to hear that you too were able to work it out!

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

ExpressionEngine News!

#eecms, #events, #releases