改进模板引擎驱动的config方法 支持获取配置参数值

This commit is contained in:
thinkphp
2016-09-23 12:24:16 +08:00
parent 7d5e5fb237
commit 0d85b268e9
3 changed files with 8 additions and 2 deletions

View File

@@ -143,6 +143,8 @@ class Php
{
if (is_array($name)) {
$this->config = array_merge($this->config, $name);
} elseif (is_null($value)) {
return isset($this->config[$name]) ? $this->config[$name] : null;
} else {
$this->config[$name] = $value;
}