promo update
This commit is contained in:
@@ -54,8 +54,8 @@ abstract class BaseController extends Controller
|
|||||||
// Preload any models, libraries, etc, here.
|
// Preload any models, libraries, etc, here.
|
||||||
|
|
||||||
// E.g.: $this->session = \Config\Services::session();
|
// E.g.: $this->session = \Config\Services::session();
|
||||||
//$this->session = \Config\Services::session();
|
$this->session = \Config\Services::session();
|
||||||
$this->session = service('session');
|
// $this->session = service('session');
|
||||||
$httpHost = $_SERVER['HTTP_HOST'];
|
$httpHost = $_SERVER['HTTP_HOST'];
|
||||||
|
|
||||||
if ( $httpHost == 'https://promo.wrenchboard.com' || $httpHost == 'promo.wrenchboard.com' ){
|
if ( $httpHost == 'https://promo.wrenchboard.com' || $httpHost == 'promo.wrenchboard.com' ){
|
||||||
|
|||||||
@@ -10,9 +10,13 @@ class PromoAdmin extends BaseController
|
|||||||
|
|
||||||
public function __construct()
|
public function __construct()
|
||||||
{
|
{
|
||||||
if(!isset($_SESSION['sessionid'])){
|
$sessionid =$_SESSION['sessionid']?? '';
|
||||||
// redirect('promoadmin','refresh');
|
if(!isset($sessionid) || $sessionid=''){
|
||||||
// exit();
|
//redirect('promoadmin');
|
||||||
|
$urlLogin = base_url('promoadmin');
|
||||||
|
header('Location: '.$urlLogin);
|
||||||
|
exit;
|
||||||
|
//exit();
|
||||||
// var_dump($_SESSION?? 'No Session');
|
// var_dump($_SESSION?? 'No Session');
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user