Are there any PHP login scripts around that I can learn from?
I want to have a control panel that shows different options to different users depending on level of privilege.
Are there any PHP login scripts around that I can learn from?
I want to have a control panel that shows different options to different users depending on level of privilege.
"Login" implies authentication. "Levels of privilege" implies authorization. Although they seem similar and are often discussed together as "auth", they are quite different. "Authn" is global and simply takes in a username and password, or auth token, etc. "Authz" must be implemented at an object level and is more complicated; consider using a framework that supports it natively.
Yes, there are thousands of PHP scripts around that you can read and learn from.
You are welcome to download the framework MCRwebapp from Google Code and read the AbstractApp class to see both authentication (user password) and authorization (user permissions).