【发布时间】:2015-02-26 03:07:21
【问题描述】:
尝试将我的 laravel 应用程序放在生产服务器上时出现错误。我在我的服务器上启用了 mod_rewrite 并更改了应用程序/存储的权限
“异常处理程序中的错误”
这是我的 .htaccess 文件
<IfModule mod_rewrite.c>
Options -MultiViews
RewriteEngine On
RewriteBase /escrow/
RewriteCond %{REQUEST_FILENAME} !-d
RewriteCond %{REQUEST_FILENAME} !-f
RewriteRule ^ index.php [L]
</IfModule>
这是我的虚拟主机文件:
<VirtualHost *:80>
ServerAdmin webmaster@localhost
DocumentRoot /var/www/laravel/public/
<Directory />
Options FollowSymLinks
AllowOverride all
</Directory>
<Directory /var/www/laravel/public>
Options Indexes FollowSymLinks MultiViews
AllowOverride all
Order allow,deny
allow from all
</Directory>
ScriptAlias /cgi-bin/ /usr/lib/cgi-bin/
<Directory "/usr/lib/cgi-bin">
AllowOverride all
Options +ExecCGI -MultiViews +SymLinksIfOwnerMatch
Order allow,deny
Allow from all
</Directory>
ErrorLog ${APACHE_LOG_DIR}/error.log
# Possible values include: debug, info, notice, warn, error, crit,
# alert, emerg.
LogLevel warn
CustomLog ${APACHE_LOG_DIR}/access.log combined
【问题讨论】:
标签: php apache .htaccess mod-rewrite laravel