【发布时间】:2013-04-14 13:31:34
【问题描述】:
我正在尝试在 ubuntu12、php5 和 nginx 中设置我的第一个 fuelphp 项目,我正在按照他们在 http://ucf.github.io/fuelphp-crash-course/#Every_Building_Needs_A_Scaffold 中的教程进行操作
我遇到的问题是当我尝试访问我的应用 URL 时
http://localhost/public/messages
错误是“找不到文件”
我使用的重写规则是
root /path/to/project;
index index.php index.htm index.html;
location / {
try_files $uri $uri/ @handler;
expires 30d;
}
location @handler {
rewrite ^ /index.php?/$request_uri;
}
提前感谢您的帮助
【问题讨论】:
-
$request_uri 中已经有一个前导斜杠。所以你不应该再添加另一个。