Click here to Skip to main content
15,894,343 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
hi!

I would like to ask for thecodes on how to authenticate different type of users
and if they are already authenticated,they will be redirected to a certain web page.Example,you have only one login page and when you have logged in and when the system recognises your user type(administrator,moderator,etc.),you will be directed to the page made for you. Hope someone can help me.
Thank you :)
Posted

1 solution

When someone logs in, you store their user type in the session. Then each page checks the session to see if the user is logged in, and if not, redirects to the login page.
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900