2008年01月13日

建立完Symfony工程后,要在Apache里建立虚拟主机指向他的web目录,而且要做sf这个别名,配置文件例子如下:
<VirtualHost *:80>
    ServerAdmin webmaster@symfony
    DocumentRoot "E:/workspace/weblog/web"
    Alias /sf C:/php5/PEAR/data/symfony/web/sf
    ServerName symfony
    ServerAlias www.symfony
    RewriteEngine On
    RewriteOptions Inherit
    ErrorLog "logs/symfony-error.log"

    <Directory "E:/workspace/weblog/web">
        Options Indexes FollowSymLinks
        AllowOverride None
        Order allow,deny
        Allow from all
    </Directory>

    <Directory "C:/php5/PEAR/data/symfony/web">
        Options Indexes FollowSymLinks
        AllowOverride None
        Order allow,deny
        Allow from all
    </Directory>
</VirtualHost>