[wp-hackers] Capabilities and Plugins
Owen Winkler
ringmaster at midnightcircus.com
Sun Mar 5 14:19:41 GMT 2006
Sam Angove wrote:
> On 3/5/06, Mark Jaquith <mark.wordpress at txfx.net> wrote:
>> As it is now, there is no way for a third party role manager plugin
>> (like Owen's... is there another one?) to know about the capabilities
>> that a plugin uses unless that plugin adds the capability to an
>> existing role.
>
> Just curious, but why aren't plugins granting caps to the
> administrator role as a matter of course? They'll be able to grant it
> to themselves anyway, after all, and it seems like a good
> policy/best-practice.
Because there is no guarantee that an "administrator" role exists.
Determining which role functions in an administrative capacity can be
problematic.
>> An easy way to add the plugin's capability to all roles with
>> manage_options capability [...]
Granting caps automatically sounds like a bad idea to me. Logically
speaking, why have a new capability at all, if you're going to grant the
cap to only those roles that already have manage_options?
Owen
More information about the wp-hackers
mailing list