选择语言 :

 Core_View::set_global

设置全局视图变量

null Core_View::set_global( string/array $key [, mixed $value = null ] )

参数列表

参数 类型 描述 默认值
$key string/array $key
$value mixed $value null
File: ./core/classes/view.class.php
public static function set_global($key, $value = null)
{
    if (is_array($key))
    {
        foreach ($key as $k => $v)
        {
            View::$_global_data[$k] = $v;
        }
    }
    else
    {
        View::$_global_data[$key] = $value;
    }
}