_winds 发表于 2017-4-2 12:48:53

php + acpache 配置多个虚拟目录

1. -- httpd.conf

# 将httpd.conf文件的(190到195行)
<Directory />
    Options FollowSymLinks
    AllowOverride None
    Order deny,allow
    Deny from all
</Directory>
-->改成
<Directory />
    Options Indexes FollowSymLinks
    AllowOverride None
    Order allow,deny
    Allow from all
</Directory>

# 把httpd.conf的(466行)

#Include conf/extra/httpd-vhosts.conf 改成Include conf/extra/httpd-vhosts.conf

2. -- php.ini

(1000行) ;date.timezone =改成date.timezone =Asia/Chongqing

3. -- httpd-vhosts.conf -->在apache/conf/extra 下

<VirtualHost *:80>
    ServerAdmin webmaster@dummy-host2.localhost
    DocumentRoot "E:/function"   # 为你虚拟目录的路径
    ServerName function   # 虚拟目录名
    ErrorLog "logs/function.localhost-error.log"   #错误信息
    CustomLog "logs/function.localhost-access.log" common   
</VirtualHost>

4. -- C:\WINDOWS\system32\drivers\etc\hosts 文件里配置 比如:127.0.0.1   function注:function 与 第3步 ServerName 一致
页: [1]
查看完整版本: php + acpache 配置多个虚拟目录