laravel5.2 移植到新服务器上除了“/”路由 ,其它路由对应的页面显示报404错误(Object not found!)———新装的LAMP没有加载Rewrite模块

Laravel 框架通过 public/.htaccess 文件来让网址不需要 index.php。如果你的服务器是使用 Apache,请确认是否有开启 mod_rewrite 模块。如果 Laravel 附带的 .htaccess 文件在 Apache 中无法使用的话,请尝试下方的做法:

 
Options +FollowSymLinks
RewriteEngine On
RewriteCond %{REQUEST_FILENAME} !-d
RewriteCond %{REQUEST_FILENAME} !-f
RewriteRule ^ index.php [L]
原文地址:https://www.cnblogs.com/caicaizi/p/6034374.html