* @param integer|Response $code 状态码 或者 Response对象实例
* @param string $message 错误信息
* @param array $header 参数
*/
function abort($code, $message = null, $header = [])
{
if ($code instanceof Response) {
throw new HttpResponseException($code);
} else {
throw new HttpException($code, $message, null, $header);
}
}
}
if (!function_exists('action')) {
/**
* 调用模块的操作方法 参数格式 [模块/控制器/]操作
* @param string $url 调用地址
* @param string|array $vars 调用参数 支持字符串和数组
PHPSESSID | e7n6faglu6k8f6dr3ceo2e6mv1 |
USER | www |
HOME | /home/www |
HTTP_COOKIE | PHPSESSID=e7n6faglu6k8f6dr3ceo2e6mv1 |
HTTP_ACCEPT_ENCODING | gzip |
HTTP_ACCEPT | */* |
HTTP_HOST | www.hmnzy.com |
HTTP_USER_AGENT | Mozilla/5.0 (compatible; SemrushBot/7~bl; +http://www.semrush.com/bot.html) |
PATH_INFO | |
REDIRECT_STATUS | 200 |
SERVER_NAME | hmnzy.com |
SERVER_PORT | 80 |
SERVER_ADDR | 172.30.42.215 |
REMOTE_PORT | 53558 |
REMOTE_ADDR | 170.130.200.86 |
SERVER_SOFTWARE | nginx/1.18.0 |
GATEWAY_INTERFACE | CGI/1.1 |
REQUEST_SCHEME | http |
SERVER_PROTOCOL | HTTP/1.1 |
DOCUMENT_ROOT | /www/wwwroot/hmnzy.cn/public |
DOCUMENT_URI | /index.php |
REQUEST_URI | /product/22/ |
SCRIPT_NAME | /index.php |
CONTENT_LENGTH | |
CONTENT_TYPE | |
REQUEST_METHOD | GET |
QUERY_STRING | s=/product/22/ |
SCRIPT_FILENAME | /www/wwwroot/hmnzy.cn/public/index.php |
FCGI_ROLE | RESPONDER |
PHP_SELF | /index.php |
REQUEST_TIME_FLOAT | 1674732502.5985 |
REQUEST_TIME | 1674732502 |
HTTP_TYPE | http:// |
HTTP_HOST | www.hmnzy.com |
APP_DEBUG | true |
CMF_ROOT | /www/wwwroot/hmnzy.cn/ |
CMF_DATA | /www/wwwroot/hmnzy.cn/data/ |
APP_PATH | /www/wwwroot/hmnzy.cn/app/ |
WEB_ROOT | /www/wwwroot/hmnzy.cn/public/ |
HTMLPURIFIER_PREFIX | /www/wwwroot/hmnzy.cn/vendor/ezyang/htmlpurifier/library |