httpd-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Eugene <httpd.subscr...@infosatgeomatica.com>
Subject Re: [users@httpd] Multiple Virtual Hosts Problem
Date Thu, 09 Sep 2004 05:36:38 GMT
Hello operationsengineer1, try to configure Name Based virtual host:
 <VirtualHost *:80>
 DocumentRoot "C:/web/site1"
 ServerName site1.com
 </VirtualHost>

Or you can try to change IP binding(your vhosts (or hosts on Windows) file):
 127.0.0.1 localhost
 127.0.0.2 site1.com

then configure Vhost:
 <VirtualHost 127.0.0.2>
 DocumentRoot "C:/web/site1"
 ServerName site1.com
 </VirtualHost>


Wednesday, September 8, 2004, 9:47:03 PM, you wrote:

> Hi all, i'm having trouble getting multiple virtual
> hosts to recognize subdirectories of my web server
> root directory. i go over my phpini, hosts and
> httpd.conf file additions/edits and then i discuss the
> unexpected results that i'm getting. tia for any
> suggestions to get back to the land of the expected.


> PHP.INI FILE

> doc_root = "c:\web"
> extension_dir = "c:\php\extensions"
> extension=php_pgsql.dll 
> extension=php_dbg.dll-4.3.6


> HOSTS

> 127.0.0.1 localhost
> 127.0.0.1 site1.com


> HTTPD.CONF

> ServerName localhost
> ...
> DocumentRoot "C:/web"
> ...
> <Directory "C:/web">
> ...
> DirectoryIndex index.php index.htm index.html
> ...
> SetEnv PHPRC "c:/php"
> ScriptAlias /php/ "c:/php/"
> AddType application/x-httpd-php .php
> AddType application/x-httpd-php .htm
> AddType application/x-httpd-php .html
> Action application/x-httpd-php "/php/php.exe"
> ...
> NameVirtualHost 127.0.0.1
> <VirtualHost 127.0.0.1>
> DocumentRoot "C:/web"
> ServerName site1.com
> </VirtualHost>

> when i type in localhost or site1.com into my browser,
> i'm taken to the index.php file in c:\php as one
> wouold expect. however, when i update my virtualhost
> directive to...

> NameVirtualHost 127.0.0.1

> <VirtualHost 127.0.0.1>
> DocumentRoot "C:/web/site1"
> ServerName site1.com
> </VirtualHost>

> then i get taken right back to C:/web instead of
> C:/web/site1 when i type in site1.com. i can't get
> apache to recognize lower level folders using the
> virtualhost directive. 

> any help would be appreciated...




		
> __________________________________
> Do you Yahoo!?
> Yahoo! Mail - 50x more storage than other providers!
> http://promotions.yahoo.com/new_mail

> ---------------------------------------------------------------------
> The official User-To-User support forum of the Apache HTTP Server Project.
> See <URL:http://httpd.apache.org/userslist.html> for more info.
> To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
>    "   from the digest: users-digest-unsubscribe@httpd.apache.org
> For additional commands, e-mail: users-help@httpd.apache.org



-- 
Best regards,
 Eugene                            mailto:httpd.subscribe@infosatgeomatica.com


---------------------------------------------------------------------
The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:http://httpd.apache.org/userslist.html> for more info.
To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
   "   from the digest: users-digest-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@httpd.apache.org


Mime
View raw message