WordPress Development Stack Exchange is a question and answer site for WordPress developers and administrators. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I have put my wordpress installation liek these : http://www.mydomain.com/cms for the testing time, and time to implement thing in the database. Now i have switch the whole thing to : http://www.mydomain.com/ (root). How is it possible to tell all the request to /cms to be / (root). i know htaccess can do that, but i prefer a plugin

or how to migrate an installation from one directory to another seemlessly ?

share|improve this question

In your wp-config.php Just put this rule in there:


Put it right above:

/* That's all, stop editing! Happy blogging. */
share|improve this answer
Then I would go through with the search and replace plugin to search and replace all images and posts: wordpress.org/extend/plugins/search-and-replace – drewrowalnd Mar 6 '12 at 21:38
i wanna just make sure.... ANY request from : mydomain.com/cms like : mydomain.com/cms/paper01 will be redirected to mydomain.com/paper01... understand ?.. i just want the /cms to disapear ! and get the good page – menardmam Mar 6 '12 at 21:46
oh, so you made mydomain.com/cms public to your viewers? I think you should be able to do a wildcard redirect within your hosting account. However, I am not sure. – drewrowalnd Mar 6 '12 at 21:48
Yep !, my fault... now google found a tons of pages at /cms/xyz that need to be silently redirected to /xyz ! – menardmam Mar 6 '12 at 21:51
up vote -2 down vote accepted

htaccess : http://www.htaccessredirect.net/index.php

share|improve this answer
That’s not an answer. – toscho Mar 13 '12 at 1:52

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.