apache配置php+多站点+多目录

1、

加入

LoadModule php5_module "d:/phpa/php5apache2_2.dll"

PHPIniDir "D:/phpa"

AddType application/x-httpd-php .php

AddType application/x-httpd-php .htm

2、

Options Indexes FollowSymLinks

改成

Options -Indexes FollowSymLinks

3、

DirectoryIndex index.html

改成

DirectoryIndex index.html index.php

4、

Listen 80

改成

Listen 8080

Listen 8800

5、

最后加入

<VirtualHost localhost:8080>

    DocumentRoot "D:/weba"

</VirtualHost>

<VirtualHost localhost:8800>

    DocumentRoot "D:/wza"

</VirtualHost>

<Directory "D:/weba">

    Options -Indexes FollowSymLinks

    AllowOverride None

    Order allow,deny

    Allow from all

</Directory>

<Directory "D:/wza">

    Options -Indexes FollowSymLinks

    AllowOverride None

    Order allow,deny

    Allow from all

</Directory>

posted @ 2015-06-06 15:02  刘满blog  阅读(591)  评论(0编辑  收藏  举报