Hi everyone,

I have some problems understanding Rbac and some help would be appreciated
:-) I have never actually worked on implementing the Role-Based
authentication.

Basically, I have a simple system where user can have *one or more* roles
while each role has 1 or more permissions. So, I need to check if user has
specific permission.

I expected to have something simple like:

$rbac->hasPermission('write_article');

But, apparently, hasPermission expects the Role to be passed as first
parameter.

So, generally, I'm a bit confused with how this is supposed to work at all?

Is user supposed to have only one role, which would have some child roles
added if needed?

Any help on this subject would really be appreciated.

Thanks!

Best regards,

Mihailo Joksimovic
[email protected]
Skype: mihailo-joksimovic
GTalk: [email protected]
+381-69-2546-664

---
I do it because I can. I can because I want to. I want to because you said
I couldn't.

Reply via email to