You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@httpd.apache.org by John Donaldson <jd...@coe.ufl.edu> on 2008/03/06 20:19:15 UTC
[users@httpd] mod_rewrite to point to subdomain
I have several sites with URLs like main.server.com/mydir1/page1 and would
like to use subdomains so people could have their own personal domain that
maps to their directory. For the above example, I'd like to use
subdomain.server.com/page1, but it actually pulls the content from
main.server.com/mydir1/page1 and rewrites the URL the user sees to
subdomain.server.com/page1. It can't be a redirect as I'm using Drupal and
it delivers content based on the domain and it wouldn't know what to do with
subdomain.server.com/page1. I've tried many things, but have failed. Any
help would be greatly appreciated. I¹m running Apache 2.2.8.
John
Re: [users@httpd] mod_rewrite to point to subdomain
Posted by Joshua Slive <jo...@slive.ca>.
On Thu, Mar 6, 2008 at 2:19 PM, John Donaldson <jd...@coe.ufl.edu> wrote:
>
> I have several sites with URLs like main.server.com/mydir1/page1 and would
> like to use subdomains so people could have their own personal domain that
> maps to their directory. For the above example, I'd like to use
> subdomain.server.com/page1, but it actually pulls the content from
> main.server.com/mydir1/page1 and rewrites the URL the user sees to
> subdomain.server.com/page1. It can't be a redirect as I'm using Drupal and
> it delivers content based on the domain and it wouldn't know what to do with
> subdomain.server.com/page1. I've tried many things, but have failed. Any
> help would be greatly appreciated. I'm running Apache 2.2.8.
This is a pretty-standard configuration:
http://httpd.apache.org/docs/2.2/vhosts/mass.html#simple.rewrite
But I'm not sure how Drupal will handle it. It depends on where
exactly it is looking for its path information.
Joshua.
---------------------------------------------------------------------
The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:http://httpd.apache.org/userslist.html> for more info.
To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
" from the digest: users-digest-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@httpd.apache.org