I am using the CodeIgniter structure for PHP . There are some pages specifically for administrators and they are located in Admin / * . When the user logs in, I store some value in the session as a flag and checks in my controller to check that the user is logged in or not. I wrote the code in my controller to check the session in every method but, I realized that I did not want to write the same line of code in each method because it was made from the perspective of maintaining many issues. Then I decided to create a unique controller which would only load the admin views and thus in its constructor I would check the value of the session. Is there any other way than this approach? Am i doing it properly Or CodeIgniter
you have taken or any other safe mechanism available One of the best views (my opinion), just increase the other controller controller from that controller so that you can make special controller (admin blog, admin gallery etc.). If you need help, then I will gladly help you.
Comments
Post a Comment