June 20th, 2003, 12:58 PM
June 20th, 2003, 02:54 PM
The following assumes the different hosts you speak of are located on the same machine, same IP. If that is not the case, tell me:
This doesn't have to do with DNS. What you want is to setup virtual hosts in the apache config. Setup a specific virtual host for index.htm. then setup a default virtual host for anything else to be home.htm.
June 20th, 2003, 05:15 PM
The hosts are all on the same machine, same IP.
June 20th, 2003, 07:20 PM
mod_rewrite can do this for you. Have a read of http://www.engelschall.com/pw/apache/rewriteguide/ for some tips.
In addition to setting up Apache with virtual hosts, you will need to create wildcard DNS records. I assume you already have this set up - in this case, this thread really belongs in the Apache forum as it is no longer specific to DNS.
With regards to your Apache config, any subdomains that aren't explicitly assigned to a VirtualHost will be served by the first VirtualHost container in httpd.conf - so just make example.com the first VirtualHost, create the wildcard DNS records, and *.example.com will be served by that first VirtualHost.
Last edited by alexgreg; June 20th, 2003 at 07:28 PM.
June 20th, 2003, 07:48 PM
Thanks, I got it working!