摘要:
cookie配置 config.php 'cookie' => [ // cookie 名称前缀 'prefix' => '', // cookie 保存时间 'expire' => 0, // cookie 保存路径 'path' => '/', // cookie 有效域名 'domain' = 阅读全文
posted @ 2021-10-31 15:52
胡勇健
阅读(286)
评论(0)
推荐(0)
摘要:
session配置 config.php file配置 'session' => [ 'id' => '', // SESSION_ID的提交变量,解决flash上传跨域 'var_session_id' => '', // SESSION 前缀 'prefix' => 'think', // 驱动 阅读全文
posted @ 2021-10-31 15:51
胡勇健
阅读(293)
评论(0)
推荐(0)
摘要:
缓存独立配置文件 extra/cache.php <?php return [ // 驱动方式,type为complex时为混合类型 'type' => 'complex', // 默认使用的缓存 'default' => [ // 驱动方式 'type' => 'file', 'prefix' = 阅读全文
posted @ 2021-10-31 15:10
胡勇健
阅读(251)
评论(0)
推荐(0)
摘要:
独立验证 <?php namespace app\index\controller; use think\Controller; use think\Validate; class Index extends Controller { public function index() { $valid 阅读全文
posted @ 2021-10-31 14:20
胡勇健
阅读(127)
评论(0)
推荐(0)
摘要:
开启调试模式 .env app_debug = true 开启Trace调试 'app_trace' => true, 异常捕捉 try{ $user = Db::table('user')->where('id',6)->find(); var_dump($user); }catch(\Excep 阅读全文
posted @ 2021-10-31 13:44
胡勇健
阅读(280)
评论(0)
推荐(0)
摘要:
日志配置文件 config.php 'log' => [ // 日志记录方式,内置 file socket 支持扩展 'type' => 'File', // 日志保存目录 'path' => LOG_PATH, // 日志记录级别 'level' => [], //自动清理 'max_files' 阅读全文
posted @ 2021-10-31 00:31
胡勇健
阅读(235)
评论(0)
推荐(0)

浙公网安备 33010602011771号