How can I implement forum privileges
- by RobertPitt
I've started developing a forum application in PHP on my MVC Framework and I've got to the stage where I assign permissions to members (for example: READ, WRITE, UPDATE, DELETE).
Now, I know I can add 5 columns under the user table in my database and set them to 1 | 0, but that to me seems like too much if I want to add other rules, like MOVE for example.
And how can I dynamically assign these privileges them to users individually?
I've heard of using a bitmasks, but it would be really good if I could fully understand them before I continue.
Do you have an example of how I might implement this?