Forum Moderators: phranque

Message Too Old, No Replies

HTACCESS : Restricting direct access to subdomains & subdomain folder.

htaccess sub doamin redirect

         

new_b

12:45 pm on Sep 20, 2010 (gmt 0)

10+ Year Member



jdMorgan has posted a very detailed instruction on this, but I could not find that post so I'm posting it again.....

It talked about a set of rewrite/redirect rules (?)

I've a primary domain example.com and many addon domains (for example addon.com ,created as a subdomain addon.example.com )

What I'm trying find is the two sets of .htaccess codes that has to be put in the maindoamain & subdomain .htaccess files to accomplish the following.


1) addon.example.com should redirect to example.com
2) example.com/addon1 should redirect to example.com
3) addon.com is only directly accessible (not as above)

If someone who know the thread I mentioned above, please link it here. Any help is appreciated!

regards,
new_b