LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Server (https://www.linuxquestions.org/questions/linux-server-73/)
-   -   Dynamically virtualhosts under Apache (https://www.linuxquestions.org/questions/linux-server-73/dynamically-virtualhosts-under-apache-629682/)

Chrizzieej 03-21-2008 12:24 PM

Dynamically virtualhosts under Apache
 
Hello folks,

Is there a way to use dynamically virtualhosts under Apache?

For example:
I've got a directory /var/www/domain.com/ and I create a subdirectory www.domain.com. Can I let Apache read /var/www/domain.com/ and automatically create www.domain.com (because a directory www.domain.com exists)?

Greetz Chrizzieej

trickykid 03-21-2008 04:46 PM

It's all in mod_rewrite. Now, go read up about it. http://httpd.apache.org/docs/2.2/mod/mod_rewrite.html

datopdog 03-23-2008 03:17 AM

Actually there is a better way to do it using mod_vhost_alias http://httpd.apache.org/docs/2.2/mod...ost_alias.html


All times are GMT -5. The time now is 10:35 PM.