• Resolved sjbenson

    (@sjbenson)


    I am in way over my head.

    I have used WordPress for other projects. I offered to finish my aunt’s sites for her, because whoever had started working on them had failed to finish the project.

    What I did not know:
    She had a single ip address and all domains registered were aliased to the main domain.
    The previous main domain had been canceled and one of the aliased domains reverted to the main.
    When she re-instituted the domain and we made it the primary domain, it removed her other blog. I never backed it up properly because I did not know that was how it was going to happen. I have copies of the mysql, and most of the old files still seem to be there.

    I have literally been doing this for weeks in my spare time. For the longest time I could not get the redirects to go where I wanted them to go. Then I learned about a mult-sites and realized that it looked like the previous person had probably been trying to set that up.

    I enabled the multi-site. With some work I was able to get the aliased domain to redirect to a subdomain of the main domain that I wanted to use. However, despite going through everything I could find, I can’t seem to get anything besides a 500 internal server error when I try to use the other domain. The main is fine.

    I know all of this is vague and I’m sure that my answer is somewhere in this forum, but I’ve been searching and I’ve just realized that I’m still too much of a noob at this. If anyone can give me any advice it would be much appreciated. I apologize in advance for being totally ignorant.

Viewing 15 replies - 1 through 15 (of 30 total)
  • Moderator Ipstenu (Mika Epstein)

    (@ipstenu)

    🏳️‍🌈 Advisor and Activist

    That;s okay 🙂

    First, before we jump into domain mapping, does Multisite work in and of itself? That is, WITHOUT mapping anything, can you make a subsite and have it work?

    Thread Starter sjbenson

    (@sjbenson)

    No, when I created the subdomain it did not work.

    Thank you for your help!

    Thread Starter sjbenson

    (@sjbenson)

    Sorry for the slow reply, I’ve been working and sleeping for the past 20 hours.

    Moderator Ipstenu (Mika Epstein)

    (@ipstenu)

    🏳️‍🌈 Advisor and Activist

    S’okay, we’re all volunteers here 🙂

    Okay, let’s work on the Subdomain first.

    Check your .htaccess. Make SURE it’s the right one. Go to yourdomain.com/wp-admin/network/setup.php and match the .htacces there to what you have. Remember, you’re replacing the old WP stuff 🙂

    If that looks fine, what error are you getting on the subdomain site? Is it also an error 500?

    Thread Starter sjbenson

    (@sjbenson)

    The main domain is working, to clarify. It’s only the subdomain that is getting the 500 error.

    So I want the .htaccess in the root to match the one in wp-admin/network/setup.php? Okay, I’ll take a look

    Thread Starter sjbenson

    (@sjbenson)

    So to clarify, do I need to insert this into the root .htaccess?

    require_once( ‘./admin.php’ );

    if ( ! is_multisite() )
    wp_die( __( ‘Multisite support is not enabled.’ ) );

    require( ‘../network.php’ );

    Thread Starter sjbenson

    (@sjbenson)

    Inserting the text didn’t work, I think maybe I’m misunderstanding you. Here is the .htaaccess in the root. I changed the identifiable stuff so that my aunt’s business info is protected.

    rewriteengine on
    rewritecond %{HTTP_HOST} ^www.mydomain2.com$ [OR]
    rewritecond %{HTTP_HOST} ^mydomain2.com$
    rewriterule ^ "http\:\/\/subdomain\.mydomain1.net\.net\/subdomain" [R=301,L] #4f9b2a2587d02
    
    #uploaded files
    # add a trailing slash to /wp-admin
    <IfModule mod_security.c>
    <Files async-upload.php>
    SecFilterEngine Off
    SecFilterScanPOST Off
    </Files>
    </IfModule>
    # BEGIN WordPress
    RewriteBase /
    # uploaded files
    # END WordPress
    # BEGIN WordPress
    
    rewriterule ^index\.php$ - [L]
    rewriterule ^files/(.+) wp-includes/ms-files.php?file=$1 [L]
    rewritecond %{REQUEST_FILENAME} -f [OR]
    rewritecond %{REQUEST_FILENAME} -d
    rewriterule ^ - [L]
    rewriterule . index.php [L]
    rewriterule ^(.*/)?files/$ index.php [L]
    rewritecond %{REQUEST_URI} !.*wp-content/plugins.*
    rewriterule ^(.*/)?files/(.*) wp-content/ms-files.php?file=$2 [L]
    rewritecond %{REQUEST_URI} ^.*/wp-admin$
    rewriterule ^(.+)$ $1/ [R=301,L]
    rewritecond %{REQUEST_FILENAME} -f [OR]
    rewritecond %{REQUEST_FILENAME} -d
    rewriterule . - [L]
    rewriterule . index.php [L]
    rewriterule ^index\.php$ - [L]
    rewritecond %{REQUEST_FILENAME} !-f
    rewritecond %{REQUEST_FILENAME} !-d
    rewriterule . /index.php [L]
    
    # END WordPress

    I think there are some leftovers from the previous wp installation… does this look at all right?

    Moderator Ipstenu (Mika Epstein)

    (@ipstenu)

    🏳️‍🌈 Advisor and Activist

    When I said go to yourdomain.com/wp-admin/network/setup.php what I mean was … you know, http://yourdomain.com/wp-admin/network/setup.php

    (When we tell you to look at the files, we’ll say /wp-admin/network…. etc 😉 )

    And yeah, your .htaccess is screwed up. S’okay! We can fix. Are you using subdomains or subfolders?

    Thread Starter sjbenson

    (@sjbenson)

    Sorry, my brain is fried from looking at this too long.

    Okay, so I’m working with subdomains.

    I replaced this:

    rewriterule ^index\.php$ – [L]
    rewriterule ^files/(.+) wp-includes/ms-files.php?file=$1 [L]
    rewritecond %{REQUEST_FILENAME} -f [OR]
    rewritecond %{REQUEST_FILENAME} -d
    rewriterule ^ – [L]
    rewriterule . index.php [L]
    rewriterule ^(.*/)?files/$ index.php [L]
    rewritecond %{REQUEST_URI} !.*wp-content/plugins.*
    rewriterule ^(.*/)?files/(.*) wp-content/ms-files.php?file=$2 [L]
    rewritecond %{REQUEST_URI} ^.*/wp-admin$
    rewriterule ^(.+)$ $1/ [R=301,L]
    rewritecond %{REQUEST_FILENAME} -f [OR]
    rewritecond %{REQUEST_FILENAME} -d
    rewriterule . – [L]
    rewriterule . index.php [L]
    rewriterule ^index\.php$ – [L]
    rewritecond %{REQUEST_FILENAME} !-f
    rewritecond %{REQUEST_FILENAME} !-d
    rewriterule . /index.php [L]

    with:

    RewriteEngine On
    RewriteBase /
    RewriteRule ^index\.php$ – [L]

    # uploaded files
    RewriteRule ^files/(.+) wp-includes/ms-files.php?file=$1 [L]

    RewriteCond %{REQUEST_FILENAME} -f [OR]
    RewriteCond %{REQUEST_FILENAME} -d
    RewriteRule ^ – [L]
    RewriteRule . index.php [L]

    Didn’t fix the problem, but it still seems to be working as well as it was previously… so that’s good.

    Thread Starter sjbenson

    (@sjbenson)

    Um… let me rephrase that–I THINK I replaced it. I’m not using my computer and trying to read the .htaccess with notepad was getting me nowhere fast. Will double check when I’m back on my owm comp.

    Moderator Ipstenu (Mika Epstein)

    (@ipstenu)

    🏳️‍🌈 Advisor and Activist

    You can’t (easily) read it in notepad. It’s a hidden file and sometimes Windows is teh stupiz.

    You should do this:

    rewriteengine on
    rewritecond %{HTTP_HOST} ^www.mydomain2.com$ [OR]
    rewritecond %{HTTP_HOST} ^mydomain2.com$
    rewriterule ^ "http\:\/\/subdomain\.mydomain1.net\.net\/subdomain" [R=301,L] 
    
    <IfModule mod_security.c>
    <Files async-upload.php>
    SecFilterEngine Off
    SecFilterScanPOST Off
    </Files>
    
    RewriteEngine On
    RewriteBase /
    RewriteRule ^index\.php$ - [L]
    
    # uploaded files
    RewriteRule ^files/(.+) wp-includes/ms-files.php?file=$1 [L]
    
    RewriteCond %{REQUEST_FILENAME} -f [OR]
    RewriteCond %{REQUEST_FILENAME} -d
    RewriteRule ^ - [L]
    RewriteRule . index.php [L]
    </IfModule>

    I don’t know about that top rewrite, honestly. But if you think you need it, okay. We MAY want to remove it for now to test.

    Thread Starter sjbenson

    (@sjbenson)

    I tried it both ways–I commented out the top rewrite. Either way, I’m now getting a 404 error instead.

    The top rewrite was inserted by the provider when I told the web interface to redirect one domain to that subdomain. Eventually I want to hide that it’s redirected to a sub, but that’s unimportant for the moment. Main thing is getting it running, LOL!

    I was about to tell you that the subdomain does exist. And then I logged into the domain manager and saw that they’d redone their whole site and now I can’t find any of the subs or the aliased domains. So… that might be a problem.

    rewriteengine on
    rewritecond %{HTTP_HOST} ^www.mydomain2.com$ [OR]
    rewritecond %{HTTP_HOST} ^mydomain2.com$
    rewriterule ^ "http\:\/\/subdomain\.mydomain1.net\.net\/subdomain [R=301,L] 
    
    <IfModule mod_security.c>
    <Files async-upload.php>
    SecFilterEngine Off
    SecFilterScanPOST Off
    </Files>
    
    RewriteEngine On
    RewriteBase /
    RewriteRule ^index\.php$ - [L]
    
    # uploaded files
    RewriteRule ^files/(.+) wp-includes/ms-files.php?file=$1 [L]
    
    RewriteCond %{REQUEST_FILENAME} -f [OR]
    RewriteCond %{REQUEST_FILENAME} -d
    RewriteRule ^ - [L]
    RewriteRule . index.php [L]
    </IfModule>
    Thread Starter sjbenson

    (@sjbenson)

    Hmmm… nevermind. There it is. The subdomain exists… don’t know why it only shows up in one section and not the other. Anyhow, still getting 404 errors at the moment…

    I tried accessing the subdomain like this: subdomain.maindomain.net instead of subdomain.maindomain.net/subdomain and I get a 403 forbidden error as well.

    Moderator Ipstenu (Mika Epstein)

    (@ipstenu)

    🏳️‍🌈 Advisor and Activist

    The subdomain … exists?

    You mean you made the subdomain manually and not via wildcards?

    Thread Starter sjbenson

    (@sjbenson)

    well… yeah… was that my mistake? I did it through the host’s web interface.

    I can easily delete it.

    Update: just for the heck of it, I removed the entry from the host’s web host manager. Didn’t change a thing.

    LOL, I told you I was in over my head… every other project I’ve worked on was just small code tweaks and each of the sites had their own ftp roots. I’m a tad ignorant… and, yeah, I know I need to learn more before trying stuff like this, but I had no idea I’d be doing anything but tweaking the theme code for her. But apparently I’m not the first one to have this problem while dealing with this project… the last person gave up several years ago.

Viewing 15 replies - 1 through 15 (of 30 total)
  • The topic ‘I need help getting multisite to work!’ is closed to new replies.