Пример #1
0
-----------------------------------------------------------------*/
//不能非法包含或直接执行
if (!defined("IN_BAIGO")) {
    exit("Access Denied");
}
include_once BG_PATH_FUNC . "init.func.php";
//初始化
$arr_set = array("base" => true, "ssin" => true, "header" => "Content-Type: text/html; charset=utf-8", "db" => true, "type" => "ctl", "ssin_begin" => true);
fn_init($arr_set);
include_once BG_PATH_INC . "is_install.inc.php";
//验证是否已安装
include_once BG_PATH_INC . "is_admin.inc.php";
//验证是否已登录
include_once BG_PATH_CONTROL . "admin/ctl/pm.class.php";
//载入短信控制器
$ctl_pm = new CONTROL_PM();
//初始化短信
switch ($GLOBALS["act_get"]) {
    case "send":
        $arr_pmRow = $ctl_pm->ctl_send();
        //发送
        if ($arr_pmRow["alert"] != "y110303") {
            header("Location: " . BG_URL_ADMIN . "ctl.php?mod=alert&act_get=show&alert=" . $arr_pmRow["alert"]);
            exit;
        }
        break;
    case "show":
        $arr_pmRow = $ctl_pm->ctl_show();
        //显示
        if ($arr_pmRow["alert"] != "y110102") {
            header("Location: " . BG_URL_ADMIN . "ctl.php?mod=alert&act_get=show&alert=" . $arr_pmRow["alert"]);