一、本地ThinkPHP5项目-fastadmin项目搭建时,报错:No input file specified
1)、检查 .htaccess 文件,
#Apache
<IfModule mod_rewrite.c>
Options +FollowSymlinks -Multiviews
RewriteEngine On
RewriteCond %{REQUEST_FILENAME} !-d
RewriteCond %{REQUEST_FILENAME} !-f
# RewriteRule ^(.*)$ index.php [L,E=PATH_INFO:$1]
RewriteRule ^(.*)$ index.php?/$1 [QSA,PT,L]
# RewriteRule ^(.*)$ index.php/$1 [QSA,PT,L]
# RewriteRule ^(.*)$ index.php [L,QSA]
</IfModule>
#Nginx
#location / {
# if (!-e $request_filename){
# rewrite ^(.*)$ /index.php?s=$1 last; break;
# }
#}
2)、检查根目录设置
(fastadmin中必须以public为根目录,
以项目目录为根目录,会报错No input file specified)
二、后台登录页面验证码无法显示
在vender/topthink/think-captcha/Captcha.php文件中找到entry()方法
修改
ob_start();
// 输出图像
imagepng($this->_image);
$content = ob_get_clean();
imagedestroy($this->_image);
ob_clean();//清除缓存
三、队列配置
1、配置项
(1) application/config.php中:
// Redis配置
'redis' => [
'host' => '127.0.0.1', // redis 主机地址
'password' => '', // redis 密码
'port' => 6379, // redis 端口
'select' => 1, // redis 数据库,注意此处的选择redis库。
'timeout' => 0, // redis 超时时间
'persistent' => false, // redis 持续性,连接复用
],
(2) application/extra/queue.php
return [
'connector' => 'redis',//'database'//'Sync'
'host' => '127.0.0.1', // redis 主机地址
'password' => '', // redis 密码
'port' => 6379, // redis 端口
'select' => 1, // redis 数据库,,注意此处的选择redis库。与config一致
'timeout' => 0, // redis 超时时间
'persistent' => false, // redis 持续性,连接复用
];

2864

被折叠的 条评论
为什么被折叠?



