Take the 2-minute tour ×
WordPress Development Stack Exchange is a question and answer site for WordPress developers and administrators. It's 100% free, no registration required.

I've seen many questions and answers regarding this subject, yet I can't seem to get this to work.

Here is my setup.

I have my main domain:

www.example.com

On that domain, I've installed WP multisite as a subdomain. The root of the network sits at:

sites.example.com

I have multiple wordpress sites setup under that subdomain, all under the format of:

sites.example.com/Some-WP-Site/

Now, if I register some new domains for the purpose of pointing them to these individual wordpress sites, how would I edit my .htaccess files to achieve something like the following:

User navigates to:

www.New-Domain.com

and gets redirected to:

sites.example.com/Some-WP-Site/

all while still seeing www.New-Domain.com in the address bar.

I've managed to setup a mask where www.New-Domain.com is always displayed in the address bar, but I would like to have the structure of the site follow the domain, as the user navigates through the site.

For example,

sites.example.com/Some-WP-Site/wp-content/image.jpg

would become

www.New-Domain.com/wp-content/image.jpg

Is this at all possible?

share|improve this question
    
I don't think you can accomplish that with .htaccess redirects. In my experience, when a browser hits a .htaccess redirection, it simply goes to the new URL. What you're trying to do sounds like something you'd need to do in PHP -- possibly using WordPress's Rewrite API. (Or maybe a domain mapping plugin like this one.) –  Pat J Jun 18 '13 at 16:10
    
Thanks. I'll give those a try. –  JJT Jun 18 '13 at 17:48

Your Answer

 
discard

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

Browse other questions tagged or ask your own question.