OK I have been battling this for a week,
I have Xampp running on my home server and I am trying to get subdomains to work, I edited my windows host file so that all of these load my site,
http://localhost/ http://mydomain.com/
http://images.mydomain.com/ http://images.localhost/
I then modified my Apache conf file to add my virtual host to make the images.mydomain.com and images.localhost to load up my localhost/images folder but for some reason they load the contents of http://localhost/ as if I am going to the regular site and not a subdomain, any idea why?
NameVirtualHost *:80
<VirtualHost *:80>
DocumentRoot /htdocs/images/
ServerName images.localhost
</VirtualHost>
<VirtualHost *:80>
DocumentRoot /htdocs/images/
ServerName images.mydomain.com/
</VirtualHost>
<VirtualHost *:80>
DocumentRoot /htdocs/
ServerName mydomain.com/
</VirtualHost>