Quote:
Originally Posted by GFED
if i want to add a line such as "ServerAlias *.example.com" to my httpd.conf, but only to one domain on my server is this possible and where do I create the file?
for example full path to domain public_html is "/usr/home/***username***/domains/***userdomain***.com/public_html"
I'm guessing I just create a file named httpd.conf one level up from public_html but it's not working.
Thanks for any help on this =)
|
maybe try mod_vhost_alias
something like this
Code:
<VirtualHost *:80>
ServerName example.com
DocumentRoot /home/user/domains
VirtualDocumentRoot /home/user/domains/%0/public_html
</VirtualHost>
<VirtualHost *:80>
ServerName www
ServerAlias www.*
DocumentRoot /home/user/domains
VirtualDocumentRoot /home/user/domains/%2+/public_html
</VirtualHost>
example /home/user/domains/gfy.com/public_html will work by creating a gfy.com/ dir with a subdir of public_html
this will create them on the fly.