I'm customizing the editor role for my clients and would like them to be able to access gravity forms without relying on a plugin. This is the code for my custom role in the functions.php file...
if ( !get_role('adminlite') )
{
$caps = get_role('editor')->capabilities;
$caps = array_merge( $caps, array(
'install_plugins' => true,
'activate_plugins' => true,
'update_plugins' => true,
'delete_plugins' => true,
'list_users' => true,
'create_users' => true,
'edit_users' => true,
'delete_users' => true,
'unfiltered_upload' => true,
'edit_theme_options' => true
));
add_role( 'adminlite', 'Administrator Lite', $caps );
}
I would like to add gravity forms to it yet the following code doesn't appear to work...
if ( !get_role('adminlite') )
{
$caps = get_role('editor')->capabilities;
$caps = array_merge( $caps, array(
'install_plugins' => true,
'activate_plugins' => true,
'update_plugins' => true,
'delete_plugins' => true,
'list_users' => true,
'create_users' => true,
'edit_users' => true,
'delete_users' => true,
'unfiltered_upload' => true,
'edit_theme_options' => true,
'gravityforms_create_form' => true,
'gravityforms_delete_entries' => true,
'gravityforms_delete_forms' => true,
'gravityforms_edit_entries' => true,
'gravityforms_edit_entry_notes' => true,
'gravityforms_edit_forms' => true,
'gravityforms_edit_settings' => true,
'gravityforms_export_entries' => true,
'gravityforms_view_entries' => true,
'gravityforms_view_entry_notes' => true
));
add_role( 'adminlite', 'Administrator Lite', $caps );
}
Can Anyone help me out?