RE: [PHP-WIN] How to add more domains on apache w2k
| From: | Shrock, Court | Date: | Mon, 01 Apr 2002 22:09:57 +0000 |
| Subject: | RE: [PHP-WIN] How to add more domains on apache w2k | ||
| Groups: | php.windows | ||
| Request: | Send a blank email to php-windows+get-12870@lists.php.net to get a copy of this message | ||
You can add another domain by creating a <VirtualHost></VirtualHost> section
in your httpd.conf file for each domain you want to add. Inside this
section, you specify the document root directory to serve files from.
a sample follows (More information can be found at
http://www.apache.org/docs/vhosts/):
# this directive tells apache to use the Host header from the http request
NameVirtualHost *
# the actual virtual host container for domain1
<VirtualHost *>
ServerName www.domain1.com
ServerAlias www.domain1.com *.domain1.com
DocumentRoot c:\path\to\domain1\files
</VirtualHost>
# the actual virtual host container for domain2
<VirtualHost *>
ServerName www.domain2.com
ServerAlias www.domain2.com *.domain2.com
DocumentRoot c:\path\to\domain2\files
</VirtualHost>
> -----Original Message-----
> From: martinahingis [mailto:rauf@ug.bcc.bilkent.edu.tr]
> Sent: Monday, April 01, 2002 1:03 PM
> To: php-windows@lists.php.net
> Subject: [PHP-WIN] How to add more domains on apache w2k
>
>
> I have added a domain at my W2K machine in my network
> neighborhood, LAN ->
> DNS Settings. And when i write my ip or the domain name i
> specified, on ie,
> it goes my htdocs folder as it must do.
>
> My question is that how can i add another domain name. If I
> add it to DNS
> settings, where will its htdocs directory? A different htdocs
> or a folder
> under it? Is it about the httpd.conf file? I don't know
> dealing with more
> than one domains apache at all.
>
> thanks for help
>
> martina.
>
>
>
> --
> PHP Windows Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
>