ThinkPHP钩子和行为获取回调参数和自定义参数
0x001 自定义参数
$extra_param = "Some extra param";
Hook::add("response_end", function($params) use ($extra_param) {
Log::info("Extra: ".$extra_param);
});
$extra_param = "Some extra param";
Hook::add("response_end", function($params) use ($extra_param) {
Log::info("Extra: ".$extra_param);
});