Welcome Guest, Not a member yet? Register   Sign In
What's the best way to create 'hooks' between the database and application?
#2

[eluser]xzela[/eluser]
Interesting question.
What I did was created an Authentication library which tests to see what kind of user is looking at the website. Based on what's in their cookie/session I display different features...

Each registered user has a role assigned to them (all stored in the DB). Based on that role, they can see/do different things. When a user is logged in I store a limited copy of their profile in the session/cookie. When the user is trying to access a restricted page, I look in their profile to see what kind of role they have been assigned to. If they have the proper access I let them in otherwise I kick 'em to the curb.

It works but I'm sure there is another(better?) way to do it.

This is just what I do.


Messages In This Thread
What's the best way to create 'hooks' between the database and application? - by El Forum - 07-24-2009, 05:58 PM



Theme © iAndrew 2016 - Forum software by © MyBB