public function fetch($template, $data = [], $config = [])
{
if ('' == pathinfo($template, PATHINFO_EXTENSION)) {
// 获取模板文件名
$template = $this->parseTemplate($template);
}
// 模板不存在 抛出异常
if (!is_file($template)) {
throw new TemplateNotFoundException('template not exists:' . $template, $template);
}
// 记录视图信息
$this->app
->log('[ VIEW ] ' . $template . ' [ ' . var_export(array_keys($data), true) . ' ]');
$this->template->fetch($template, $data, $config);
}
6a992d5529f459a44fee58c733255e86 | { "current_page": 1 } |
USER | www |
HOME | /home/www |
HTTP_HOST | www.ccrq.com.cn |
HTTP_USER_AGENT | claudebot |
HTTP_ACCEPT | */* |
PATH_INFO | |
REDIRECT_STATUS | 200 |
SERVER_NAME | 39.107.235.255 |
SERVER_PORT | 80 |
SERVER_ADDR | 172.23.115.118 |
REMOTE_PORT | 39118 |
REMOTE_ADDR | 44.197.251.102 |
SERVER_SOFTWARE | nginx/1.20.2 |
GATEWAY_INTERFACE | CGI/1.1 |
REQUEST_SCHEME | http |
SERVER_PROTOCOL | HTTP/1.1 |
DOCUMENT_ROOT | /www/wwwroot/web |
DOCUMENT_URI | /index.php |
REQUEST_URI | /shop.aspx |
SCRIPT_NAME | /index.php |
CONTENT_LENGTH | |
CONTENT_TYPE | |
REQUEST_METHOD | GET |
QUERY_STRING | s=/shop.aspx |
SCRIPT_FILENAME | /www/wwwroot/web/index.php |
FCGI_ROLE | RESPONDER |
PHP_SELF | /index.php |
REQUEST_TIME_FLOAT | 1710844795.5968 |
REQUEST_TIME | 1710844795 |
TPL_PATH_NAME | tpl |
STATIC_PATH_NAME | static |
__PUBLIC__ | /www/wwwroot/web/tpl/public/ |
DS | / |
ADDONS_PATH | ./addons/ |