• Resolved mjcjr

    (@mjcjr)


    The Setup
    I have just completed a fresh install of a WordPress 3.8.1 Network (Multisite) using subdomains. It currently has 2 sites, the primary install and a subdomain. The Registrar is GoDaddy, but the URL has been pointed to the nameservers directly. I have added the DNS wildcard using cPanel. The .htaccess is configured with the rules supplied by the Network setup, and the wp-config file has been edited as per the setup instructions. I have cleared my DNS, flushed the cookies and given appropriate time for propagation.

    The Issue
    I can view both sites (using the individual domains) and I can login to the primary install’s Dashboard (using a super user account). I cannot, however, login to the subdomain’s Dashboard. All I get is a 404 when I try to go to the dashboard.

    The Ask
    I have read countless posts, most refer to pre 3.3.1 framework that includes the MU Domain Mapping Plugin (although I did try it without success). And I have read the codex, but it too seems dated. This leads me to ask the following:
    1. Does the MU DNS Mapping Plugin work with 3.8.1
    2. Do I need an entry in my .htaccess file to set the upload location?
    a. # uploaded files
    RewriteRule ^([_0-9a-zA-Z-]+/)?files/(.+) wp-includes/ms-files.php?file=$2 [L]
    3. Should my subdomain site settings tab have the following or blank entries?
    a. Upload Path: wp-content/blogs.dir/3/files
    b. File Upload URL: http://subsite.primarydomain.com/files

    Setup steps
    1. Went to my domain host (GoDaddy) and set the nameserver for “domain.com” and “domain2.com” to my Hostgator settings.
    2. In HostGator Cpanel I created the Addon Domain for domain.com that points to public_html/domain.com
    3. Still in Cpanel, I setup a wildcard subdomain for domain.com that points to public_html (not redirected)
    4. Still in Cpanel, I set up a subdomain entry for “domain2.domain.com” that points to domain.com’s public_html and NOT public_html/test1 (which is the default for subdomains and not redirected)
    5. Installed WordPress under public_html/domain.com folder
    6. Added the following:
    Add the following to your .htaccess file in /, replacing other WordPress rules:

    RewriteEngine On
    RewriteBase /
    RewriteRule ^index\.php$ - [L]
    # add a trailing slash to /wp-admin
    RewriteRule ^wp-admin$ wp-admin/ [R=301,L]
    
    RewriteCond %{REQUEST_FILENAME} -f [OR]
    RewriteCond %{REQUEST_FILENAME} -d
    RewriteRule ^ - [L]
    RewriteRule ^(wp-(content|admin|includes).*) $1 [L]
    RewriteRule ^(.*\.php)$ $1 [L]
    RewriteRule . index.php [L]

    Add the following to your wp-config.php file

    /* Multisite */
    define( 'WP_ALLOW_MULTISITE', true );
    define('MULTISITE', true);
    define('SUBDOMAIN_INSTALL', true);
    define('DOMAIN_CURRENT_SITE', 'domain.com');
    define('PATH_CURRENT_SITE', '/');
    define('SITE_ID_CURRENT_SITE', 1);
    define('BLOG_ID_CURRENT_SITE', 1);

    7. Log in to wordpress site that has the “multisite” feature set up and installed the “WordPress MU Domain Mapping” plugin and network activated it.
    8. Went to “my sites”>>”network admin”>>”sites”
    9. Added a new site with the “site address” as “domain2.domain.com” and title as “test1” and email address of my super-admin.
    10. Went back to my main wordpress dashboard, went to “my Sites”>>”test1″>>”dashboard”
    a. I get a 404 error from HostGator
    11. Went to domain.com/wp-admin
    a. I get a 404 error from HostGator
    12. Went to “My Sites”>>”test1″>>”visit”
    a. I get a replica of domain.com at url: domain2.domain.com
    13. If it was working, I should be able to Log in to test1 dashboard!
    14. Go to “tools”>>”domain mapping” (still in test1’s site’s dashboard
    15. Enter “domain2.com” in the text field and check the “Primary Address” button, then clicked “ADD”
    16. Check the URL, and have “domain2.com” go to “test1”.

Viewing 11 replies - 1 through 11 (of 11 total)
  • Thread Starter mjcjr

    (@mjcjr)

    I forgot to mention I have a baby croc shared hosting plan with HostGator

    Moderator Ipstenu (Mika Epstein)

    (@ipstenu)

    🏳️‍🌈 Advisor and Activist

    1. Does the MU DNS Mapping Plugin work with 3.8.1

    Yes. Works on 3.9-trunk too 🙂

    Do I need an entry in my .htaccess file to set the upload location?
    a. # uploaded files
    RewriteRule ^([_0-9a-zA-Z-]+/)?files/(.+) wp-includes/ms-files.php?file=$2 [L]

    If you installed and activated Multisite AFTER WP 3.5, no.

    3. Should my subdomain site settings tab have the following or blank entries?
    a. Upload Path: wp-content/blogs.dir/3/files
    b. File Upload URL: http://subsite.primarydomain.com/files

    Blank.

    Thread Starter mjcjr

    (@mjcjr)

    Thanks Mika for answering my questions. I still need a resolution for not being able to access the subdomain’s dashboard!

    Thread Starter mjcjr

    (@mjcjr)

    Update: I was wrong; domain2.domain.com for “test1” subdomain results in a hostgator getting started page and domain2.domain.com/wp-admin gets a 404 error.

    I discovered why I was getting a false page for domain2.domain.com. There was an index.php file in public_html/ that was forwarding to another addon domain “domain3.com” WordPress site I have that uses the same template as the others, so I disabled it. here is the code:

    /** Loads the WordPress Environment and Template */
    require( dirname( __FILE__ ) . '/domain3.com/wp-blog-header.php' );

    I am wondering if in step 3, the wildcard subdomain for domain.com should be public_html/domain.com

    Thread Starter mjcjr

    (@mjcjr)

    In my domain.com dadabase I have the following tables I’m guessing relate to the subdomain site “test1”
    sss_5_commentmeta
    sss_5_comments
    sss_5_links
    sss_5_options
    sss_5_postmeta
    sss_5_posts
    sss_5_terms
    sss_5_term_relationships
    sss_5_term_taxonomy

    The options table has the site URL and Home which look ok.
    I added the blogs.dir folder in wp-content as some sites instruct to do, but it’s empty.

    Question: Where are the files that make up the subdomains supposed to be located?

    Moderator Ipstenu (Mika Epstein)

    (@ipstenu)

    🏳️‍🌈 Advisor and Activist

    Question: Where are the files that make up the subdomains supposed to be located?

    Same place all the other files are. The folders and files per subdomain are virtual.

    Update: I was wrong; domain2.domain.com for “test1” subdomain results in a hostgator getting started page and domain2.domain.com/wp-admin gets a 404 error.

    So that means you parked your subdomains wrong. They need to point to domain.com – NORMALLY a subdomain points to domain.com/subdomain

    All you need to do is in your cpanel add a subdomain named *

    And have it point to your public_html. This sets up wildcard dns. From there the .htaccess file will handle the rest.

    Thread Starter mjcjr

    (@mjcjr)

    Thank You for your suggestions.

    All you need to do is in your cpanel add a subdomain named *
    And have it point to your public_html. This sets up wildcard dns. From there the .htaccess file will handle the rest.

    Refer to Step 3. Still in Cpanel, I setup a wildcard subdomain for domain.com that points to public_html (not redirected)

    So that means you parked your subdomains wrong. They need to point to domain.com – NORMALLY a subdomain points to domain.com/subdomain

    I parked domain2 to public_html, which is the only option; could this be my problem?

    Thread Starter mjcjr

    (@mjcjr)

    I tried changing this subdomain:
    domain2.domain.com to document root: public_html/domain.com
    and I can now access the dashboard and completed these steps:

    13. Log in to “test1” dashboard!
    14. Go to “tools”>>”domain mapping” (still in test1’s site’s dashboard
    15. Enter “domain2.com” in the text field and check the “Primary Address” button, then clicked “ADD”
    16. Check the URL, and have “domain2.com” go to “test1”.

    domain2.com still has hostgator getting started page. I will check again to see if it updates after a few hours.
    Should this domain be parked at public_html?

    Thread Starter mjcjr

    (@mjcjr)

    1. Log in to “test1” dashboard!
    2. Go to “tools”>>”domain mapping” (still in test1’s site’s dashboard
    3. Enter “domain2.com” in the text field and check the “Primary Address” button, then clicked “ADD”
    4. Check the URL, and have “domain2.com” go to “test1”.
    5. Park the domain2.com in Cpanel

    I still get the HostGator Parked domain page instead of the domain2.com “test1” site.

    For some reason the plugin isn’t mapping my domain.

    Moderator Ipstenu (Mika Epstein)

    (@ipstenu)

    🏳️‍🌈 Advisor and Activist

    It’s not the plugin. You’re not even GETTING to the plugin.

    Go ask HostGator what you did wrong, btu what it is, is that you told their servers the wrong thing somehow.

    If it was the plugin done wrong, you’d get redirected to a registration page or the main site of the network. That you’re getting a HostGator error means, 100% without a doubt, the issue is how you set up your domain with THEM.

    Thread Starter mjcjr

    (@mjcjr)

    If anyone is getting WordPress 3.8.1 Multisite subdomain dashboard inaccessible problems like mine, the problem was back in step 4.

    Still in Cpanel, I set up a subdomain entry for “domain2.domain.com” that points to domain.com’s public_html and NOT public_html/domain.com(not redirected)

    It should have been public_html/domain.com (which is the default)
    After I changed this I was able to access the dashboard.

Viewing 11 replies - 1 through 11 (of 11 total)
  • The topic ‘WordPress 3.8.1 Multisite subdomain dashboard inaccessible’ is closed to new replies.