You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@httpd.apache.org by Bryan Henry <br...@mail.utexas.edu> on 2002/04/02 23:42:09 UTC

virtual hosts serving wrong index.php files

I am stumped by this.  Everything had been working fine 
until I started using index.php files on my virtual hosts
in replace of index.html

While using index.html files on my virtual hosts, 
each call to myvirtual.example.net returns the right 
index.html file.

Changing that to index.php on my virtual hosts, 
each call to myvirtual.example.net returns 
the index.php file from myroot.example.net.

All requests to myroot.example.net work as expected.

Do I have to put directives in the <VirtualHost *> to 
set DirectoryIndex and handling of .php extensions?
I thought this all was inherited???

thanks
~ b r y a n

My configuration is as follows:
_______________________________
Apache 2.0.28 Windows
PHP 4.1.2 CGI
_______________________________

NameVirtualHost *

<VirtualHost *>
    DocumentRoot "C:/Program Files/Apache Group/Apache2/htdocs"
    ServerName myroot.example.net
    ServerAdmin myroot@mymail.com
</VirtualHost>

<VirtualHost *>
    DocumentRoot "C:/Program Files/Apache Group/Apache2/htdocs/myvirtual"
    ServerPath "C:/Program Files/Apache Group/Apache2/htdocs/myvirtual" 
    ServerName myvirtual.example.net
    ServerAdmin myvirtual@mymail.com
    ErrorLog logs/myvirtual.example.net-error.log
    CustomLog logs/myvirtual.example.net-access.log common
</VirtualHost>

---------------------------------------------------------------------
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
For additional commands, e-mail: users-help@httpd.apache.org