コード例 #1
0
session_start();
if (empty($_SESSION['auth_id'])) {
    //'请先登入会员账号'
    $ret['status'] = 1;
    echo json_encode($ret);
    exit;
} else {
    include_once '/var/www/html/site/lib/config.php';
    include_once LIB_DIR . "/helpers.php";
    include_once LIB_DIR . "/router.php";
    include_once LIB_DIR . "/dbconnect.php";
    include_once LIB_DIR . "/ini.php";
    //$app = new AppIni;
    $c = new Bid();
    $c->home();
}
class Bid
{
    public $userid = '';
    //下标结账
    public function home()
    {
        global $db, $config, $router;
        // 初始化資料庫連結介面
        $db = new mysql($config["db"]);
        $db->connect();
        $router = new Router();
        $this->userid = empty($_SESSION['auth_id']) ? '' : $_SESSION['auth_id'];
        $ret['status'] = 0;
        // Check Variable Start