View类增加http方法,用于设置视图输出参数。

This commit is contained in:
thinkphp
2013-04-06 16:04:01 +08:00
parent 263598458f
commit 4f3f63a3bb

View File

@@ -102,6 +102,21 @@ class View {
return $content;
}
/**
* 视图输出参数设置
* @access public
* @param mixed $config
* @param mixed $value
*/
public function http($config=[],$value=''){
if(is_array($config)) {
$this->config = array_merge($this->config,$config);
}else{
$this->config[$config] = $value;
}
return $this;
}
/**
* 输出内容文本可以包括Html
* @access private