各位高手!
由于本人对Thinkphp5还是菜鸟,有个问题请教各位大神;最近我们公司有一个Thinkphp5开发的项目,我本人用nginx配置访问出现admin.php模块不存在?
nginx配置如下:
server {
listen 80;
server_name xbby.com;
location / {
root E:/www/xb.necb.org.cn/public;
index index.html index.htm index.php;
if (!-e $request_filename) {
rewrite ^(.*)$ /index.php?s=/$1 last;
}
}
location ~ \.php$ {
root E:/www/xb.necb.org.cn/public;
fastcgi_pass 127.0.0.1:9000;
fastcgi_index index.php;
fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
include fastcgi_params;
}
}
admin.php代码如下:
define('APP_PATH', __DIR__ . '/../application/');
// 判断是否安装
if (!is_file(APP_PATH . 'admin/command/Install/install.lock')) {
header("location:./install.php");
exit;
}
// 加载框架引导文件
require __DIR__ . '/../thinkphp/base.php';
// 绑定到admin模块
\think\Route::bind('admin');
// 关闭路由
\think\App::route(false);
// 设置根url
\think\Url::root('');
// 执行应用
\think\App::run()->send();
请教高手要如何配置修改?
入口为admin.php 但是配置的为index.php