• 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Have to be signed in to view page - how to accomplish

I would like some pages that users have to be signed in to view.

- I auto-load 'session'
- I manual load a custom helper on the controllers in which I need the user to be signed in


Sample controller that needs authorization:
class Account ... {

    function settings()

Sample login_authorization to check if user is signed in, if not redirect

I get an error saying that the session library is not loaded yet

Quote:Message: Undefined property: CI_Loader::$session

Any better way to do this? Or a fix?

Digg   Delicious   Reddit   Facebook   Twitter   StumbleUpon  

  Theme © 2014 iAndrew  
Powered By MyBB, © 2002-2020 MyBB Group.