Posts tagged " wordpress mu "

Migrating WPMU To Subdirectory

November 11th, 2009 Posted by General 2 comments

6 Steps to Move WPMU with Domain Mapping from Root Folder to Subdirector!

I really do appreciate the WordPress Community.  Recently I had a lot of difficulties with the technical aspects of working with WordPress MU.  I wanted to move all of the files from the root folder into a subdirectory.  In the process I had a lot of help.  I’m usually the silent reader – seldom do I post a comment. I’m like a sponge: soaking up all the information. Today, I like to contribute by sharing my tip bits here because I couldn’t find the information on the Internet that will perfectly solve my problem.

This is simple:

1) Create your subdirectory (example: /public_html/subdirectory/)

2) Move all of your WordPress MU files into the subdirectory.

3) Create a file in the root (/public_html/) and name it .htaccess

4) Go to the bottom and copy the code below and paste it into your .htaccess file (located in root (/public_html/).  Be careful to paste the code in the empty .htaccess file because there are many .htaccess files.

5) If you are using domain mapping you will usually have the domain parked, so go to your cpanel and delete the domains you parked (pointing to the root /public_html/).

6) Now, this is the secret that took me 4 days to figure out with the help of my hosting company.  They did a fantastic job.  Go to your cpanel and instead of parking the domains, create it as an add-on domain pointing to the subdirectory you had created above. If you are unable to do for any reason contact your hosting company and they can manually place an add-on for the domain.

Code Below:

# Turn on rewrites.

RewriteEngine on

# Only apply to URLs on this domain

RewriteCond %{HTTP_HOST} ^(www.)?$

# Only apply to URLs that aren’t already under folder.

RewriteCond %{REQUEST_URI} !^/your subdirectory path/

# Don’t apply to URLs that go to existing files or folders.

RewriteCond %{REQUEST_FILENAME} !-f

RewriteCond %{REQUEST_FILENAME} !-d

# Rewrite all those to insert /folder.

RewriteRule ^(.*)$ /your subdirectory path/$1

# Also redirect the root folder.

RewriteCond %{HTTP_HOST} ^(www.)?$

RewriteRule ^(/)?$ /your subdirectory path/index.php[L]

Copyright 2009 by Farting Camel


Shia_LaBeouf_Carey_Mulligan_holding_hands Shia_LaBeouf_Carey_Mulligan_Memorial_1 Shia_LaBeouf_Carey_Mulligan_Memorial_2 Shia_LaBeouf

Topics on Farting Camel