Session Library - Printable Version +- CodeIgniter Forums (https://forum.codeigniter.com) +-- Forum: Using CodeIgniter (https://forum.codeigniter.com/forumdisplay.php?fid=5) +--- Forum: General Help (https://forum.codeigniter.com/forumdisplay.php?fid=24) +--- Thread: Session Library (/showthread.php?tid=77128) |
Session Library - mongoose1130 - 07-22-2020 Codeigniter noob here: I'm trying to find how I can load the session library at app run since I plan on using several session variables throughout. I'm sure I am missing something. Can anyone point me to the right place? Thanks. RE: Session Library - jreklund - 07-22-2020 CodeIgniter version? RE: Session Library - mongoose1130 - 07-22-2020 (07-22-2020, 12:20 PM)jreklund Wrote: CodeIgniter version?4.0.4 (sorry) RE: Session Library - jreklund - 07-22-2020 Then you can just open up /app/Controllers/BaseController.php and uncomment: Code: // $this->session = \Config\Services::session(); And you can access it with $this->session in your controllers. RE: Session Library - mongoose1130 - 07-22-2020 (07-22-2020, 12:24 PM)jreklund Wrote: Then you can just open up /app/Controllers/BaseController.php and uncomment:Right on! Thanks! |