0

I am trying to develop a web application with codeigniter where some information will be stored. To see those information users have to create an account and login. But after registration users need admins approval. If admin approve user registration request , then the user can login and see the information. Otherwise if user try to login , he/she will get an error message.

I have successfully developed user registration and login system with codeigniter library "ION AUTH" but the problem is that it needs admin approval, which I dont know how to do it with "ION AUTH" library. Please somebody help me to do it.

Mushfiqul Tuhin
  • 666
  • 6
  • 13
  • 31

1 Answers1

0

In application/config/ion_auth.php set

$config['email_activation']           = FALSE;  // Email Activation for registration    
$config['manual_activation']          = TRUE;  // Manual Activation for registration

so that the user will not be active after registration. Now admin can manually enable an account from backend using function activate() and function deactivate() in auth controller . This functionality is already implemented in function index().You can also send a mail to admin regarding new user registration .

Arun Unnikrishnan
  • 2,339
  • 2
  • 25
  • 39