Beispiel #1
0
global $_mainFrame;
// Xu ly hoac chua thong tin o muc he thong
global $_pgR;
// Tat ca parameter duoc truyen tu client. Trong code se khong dung $_GET hay $_POST nua.
global $_logger;
// Duoc su dung duy nhat trong global_common::writeLog(...)
global $_cacheXMLInfo;
// Quy dinh thong tin cache cho cac file XML
global $_cacheSQLInfo;
// Quy dinh thong tin cache cho cac cau truy can SQL
global $_cacheBusinessInfo;
// Quy dinh thong tin cache cho mot nghiep vu nao do
global $_mobileDetect;
// Detect co dang dung di dong ko
// Khoi tao gia tri cho global variables
$_pgR = global_common::getRequest();
// Create new object connection
$objConnection = new db_connection();
// Kiem tra xem dang o Front-end hay Back-end
$arrPath = explode('/', $_SERVER['SCRIPT_FILENAME']);
$strModule = $arrPath[count($arrPath) - 2];
if ('admin' == $strModule) {
    $_objSystem = new global_system(global_system::LCT_BACK_END);
} else {
    $_objSystem = new global_system(global_system::LCT_FRONT_END);
}
/*
if(!global_common::isCLogin() && $_objSystem->_pName!='index')
{
	echo '<script>alert("Không được phép truy cập khi chưa login.");</script>';
	global_common::redirectByScript('index.php');