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);
}
cy_lang | zh |
USER | www |
HOME | /alidata/www |
HTTP_COOKIE | cy_lang=zh |
HTTP_ACCEPT_ENCODING | gzip |
HTTP_ACCEPT | */* |
HTTP_HOST | www.600711.com |
HTTP_USER_AGENT | Mozilla/5.0 (Macintosh; Intel Mac OS X 10_10_1) AppleWebKit/600.2.5 (KHTML, like Gecko) Version/8.0.2 Safari/600.2.5 (Amazonbot/0.1; +https://developer.amazon.com/support/amazonbot) |
PHP_ADMIN_VALUE | open_basedir=/alidata/wwwroot/www.600711.com/public/:/tmp/:/proc/:/alidata/wwwroot/ |
REDIRECT_STATUS | 200 |
SERVER_NAME | www.600711.com |
SERVER_PORT | 80 |
SERVER_ADDR | 10.171.225.157 |
REMOTE_PORT | 55774 |
REMOTE_ADDR | 104.140.79.42 |
SERVER_SOFTWARE | nginx/1.18.0 |
GATEWAY_INTERFACE | CGI/1.1 |
REQUEST_SCHEME | http |
SERVER_PROTOCOL | HTTP/1.1 |
DOCUMENT_ROOT | /alidata/wwwroot/www.600711.com/public |
DOCUMENT_URI | /index.php |
REQUEST_URI | /employee_story/new_notice |
SCRIPT_NAME | /index.php |
CONTENT_LENGTH | |
CONTENT_TYPE | |
REQUEST_METHOD | GET |
QUERY_STRING | s=//employee_story/new_notice |
SCRIPT_FILENAME | /alidata/wwwroot/www.600711.com/public/index.php |
FCGI_ROLE | RESPONDER |
PHP_SELF | /index.php |
REQUEST_TIME_FLOAT | 1716039449.2655 |
REQUEST_TIME | 1716039449 |