htaccess redirects confusing

Associate
Joined
29 Dec 2007
Posts
1,414
Location
London
Hello gents, I have a question I'm not even sure is possible.

We have a few wiki's hosted by siteground.net, they're all on the same host (with a fixed IP) under sub folders.

/public_html/internal
/public_html/external

Both have the respective index.php within the folder.

The addresses currently:
internal.companywiki.com
external.companywiki.com

This is all fine and dandy but we now require that both wiki's look like they're actually

internal.wiki.company.com
external.wiki.company.com
(and if possible, have wiki.company.com point to external.wiki.company.com)

All of this needs to be without the address changing in the users browser as we plan on using our wildcard ssl for company.com

How on earth do I setup the .htaccess file to do this?

Any pointer would be appreciated. I'm trying everything I find but nothing is quite working
 
Associate
OP
Joined
29 Dec 2007
Posts
1,414
Location
London
I have setup cname records, unfortunately even when they point to internal.companywiki.com they will hit the main index.php (in /public_html), rather than go to the respective sub folders.

I know I need some sort of mod_rewrite but it's so damn confusing lol.
 
Back
Top Bottom