session = session(); $this->UserModel = new User_model(); $this->dModel = new Dashboard_model(); $this->cModel = new Common_model(); $this->creditsModel = new Member_credits_model(); $this->PackagesModel = new Packages_and_pricing_model(); $this->CreditsUsageTrackingModel = new Credits_usage_tracking_model(); $this->MailModel = new Email_template_model(); $this->VariableModel = new Variable_model(); $this->RuleModel = new Rule_model(); $this->Cart_token_model = new Cart_token_model(); helper(['form', 'url']); } public function index($token) { if(!session()->has('logged_user')) { return redirect()->to(base_url()); } else { echo 'gopi'; } } // ----------------------------------------------- }