Changing role names
-
Hi,
Id like to change the role names used in the theme, for example to change the name ‘editor’ to ‘selector’.
I found some code that purported to do this, but it doesnt work:
function wps_change_role_name() {
global $wp_roles;
if ( ! isset( $wp_roles ) )
$wp_roles = new WP_Roles();
$wp_roles->roles[‘contributor’][‘name’] = ‘Owner’;
$wp_roles->role_names[‘contributor’] = ‘Owner’;
}
add_action(‘init’, ‘wps_change_role_name’);Can someone suggest how I could do this in Speedy?
Thanks!
The topic ‘Changing role names’ is closed to new replies.
