CodeIgniter Forums
DX Auth showing views although not logged-in - Printable Version

+- CodeIgniter Forums (https://forum.codeigniter.com)
+-- Forum: Archived Discussions (https://forum.codeigniter.com/forum-20.html)
+--- Forum: Archived Libraries & Helpers (https://forum.codeigniter.com/forum-22.html)
+--- Thread: DX Auth showing views although not logged-in (/thread-26633.html)



DX Auth showing views although not logged-in - El Forum - 01-19-2010

[eluser]Mithun[/eluser]
Hi All,

I Have a problem with DX_Auth library, I have setup it, successfully able to log in and log out, change passwords etc, issue is with other controllers, whenever i tries to access any other controller method say <base_url>/opportunities/index.php i wss able to view it with out loggedin.
Do i need to check for log in like
Code:
if($this->dx_auth->is_logged_in())
in each controller or am I doing anything wrong?


DX Auth showing views although not logged-in - El Forum - 01-19-2010

[eluser]flaky[/eluser]
Yes in each of the controllers
or you create the My_Controller or some other controller and extend the controllers that need user privileges with the My_Controller.


DX Auth showing views although not logged-in - El Forum - 01-28-2010

[eluser]Mithun[/eluser]
Thank you flaky