httpd-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Neil Freeman <>
Subject [users@httpd] Subdomains of a hostname - possible?
Date Mon, 12 Jan 2004 17:55:08 GMT
I have a site whose pages contain absolute links for items such as 
pages, images, stylesheets etc.


	<img src="/images/title.jpg" />

This works fine if accessed from a proper domain (eg or from a subdomain (eg

I have an offline development system setup with LAMP with which I am 
attempting to setup subdomains which will work directly off that machine.

What I would like users to be able to do is enter the following into 
their browser:


and have it access a local subdomain, eg


The main virtual host I have setup for the machine is as follows:

		DocumentRoot /www.main/www
		ServerName mymachine
	<Directory "/www.main/www">
		AllowOverride All

This works fine. I thought I could set up another virtual host for this 
new subdomain as follows but it doesn't work:

		DocumentRoot /www.site1/www
		ServerName site1.mymachine
	<Directory "/www.site1/www">
		AllowOverride All

It doesn't matter if I have to setup/change hosts files as long as I can 
get the set up to work.

Any suggestions as to how other people manage this would be greatly 




This communication is confidential to the intended recipient(s). If you are not that person
you are not permitted to make use of the information and you are requested to notify the sender
immediately of its receipt then destroy the copy in your possession. Any views or opinions
expressed are those of the originator and may not represent those of Advanced System Architectures

*** This Email Has Been Virus Checked ***

The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:> for more info.
To unsubscribe, e-mail:
   "   from the digest:
For additional commands, e-mail:

View raw message