www.gusucode.com > baigo CMS PHP开源网站管理系统 v1.2.2源码程序 > baigocms_v1.2.2/bg_core/control/admin/ctl/alert.class.php

    <?php
/*-----------------------------------------------------------------
!!!!警告!!!!
以下为系统文件,请勿修改
-----------------------------------------------------------------*/

//不能非法包含或直接执行
if(!defined("IN_BAIGO")) {
    exit("Access Denied");
}

include_once(BG_PATH_CLASS . "tpl.class.php"); //载入模板类

/*-------------提示信息控制器-------------*/
class CONTROL_ALERT {

    public $obj_tpl;

    function __construct() { //构造函数
        $this->obj_base       = $GLOBALS["obj_base"]; //获取界面类型
        $this->config         = $this->obj_base->config;
        $this->adminLogged    = $GLOBALS["adminLogged"];
        $_arr_cfg["admin"] = true;
        $this->obj_tpl        = new CLASS_TPL(BG_PATH_TPLSYS . "admin/" . $this->config["ui"], $_arr_cfg); //初始化视图对象
    }


    /** 显示提示信息
     * ctl_show function.
     *
     * @access public
     * @return void
     */
    function ctl_show() {
        $_str_alert   = fn_getSafe(fn_get("alert"), "txt", "");

        $arr_data = array(
            "adminLogged"    => $this->adminLogged,
            "alert"          => $_str_alert,
            "status"         => substr($_str_alert, 0, 1),
            "view"           => $GLOBALS["view"],
        );

        $this->obj_tpl->tplDisplay("alert.tpl", $arr_data);
    }

}