populate_roles_250() WordPress Function
This function will add roles and capabilities to a WordPress site. It is useful for adding new user roles or capabilities when creating a new plugin or theme.
populate_roles_250() #
Create and modify WordPress roles for WordPress 2.5.
Source
File: wp-admin/includes/schema.php
function populate_roles_250() { $role = get_role( 'administrator' ); if ( ! empty( $role ) ) { $role->add_cap( 'edit_dashboard' ); } }
Expand full source codeCollapse full source codeView on TracView on GitHub
Changelog
Version | Description |
---|---|
2.5.0 | Introduced. |