CONTROL_REG::ctl_form PHP Method

ctl_form() public method

public ctl_form ( )
    function ctl_form()
    {
        $_str_alert = fn_getSafe(fn_get("alert"), "txt", "");
        $_arr_tplData = array("alert" => $_str_alert);
        $this->obj_tpl->tplDisplay("reg_form.tpl", $_arr_tplData);
        return array("alert" => "y010102");
    }

Usage Example

Example #1
0
$ctl_reg = new CONTROL_REG();
switch ($GLOBALS["act_get"]) {
    case "confirm":
        $arr_regRow = $ctl_reg->ctl_confirm();
        //激活
        if ($arr_regRow["alert"] != "y010102") {
            header("Location: " . BG_URL_USER . "ctl.php?mod=reg&act_get=form&alert=" . $arr_regRow["alert"]);
            exit;
        }
        break;
    case "forgot":
        $arr_regRow = $ctl_reg->ctl_forgot();
        //忘记密码
        if ($arr_regRow["alert"] != "y010102") {
            header("Location: " . BG_URL_USER . "ctl.php?mod=reg&act_get=form&alert=" . $arr_regRow["alert"]);
            exit;
        }
        break;
    case "mailbox":
        $arr_regRow = $ctl_reg->ctl_mailbox();
        //更换邮箱
        if ($arr_regRow["alert"] != "y010102") {
            header("Location: " . BG_URL_USER . "ctl.php?mod=reg&act_get=form&alert=" . $arr_regRow["alert"]);
            exit;
        }
        break;
    default:
        $arr_regRow = $ctl_reg->ctl_form();
        //注册
        break;
}