Quantcast
Channel: CodeIgniter Forums - All Forums
Viewing all articles
Browse latest Browse all 14346

Community auth for full password protected website

$
0
0
I need some support on this.

I have a full password protected website on several controllers.

All I need is being able to check if there someone is logged in and if yes display the views or login form.


PHP Code:
if(  if$this->require_min_level(0) ) 
{

//my stuff



Is there a possiblity to make the check in the __construct() ?

For now it's working in the same controller (not in the construct but in each function) but if I want to go to another controller after login it give me again the login form like the user is not logged in correctly.
Should I make a  if( $this->require_min_level(0) ) on the main controller and a if( $this->verify_min_level(0) ) in the other controllers ?


I'm lost here.

Thanks again

Viewing all articles
Browse latest Browse all 14346

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>