Forums

The forums ran from 2008-2020 and are now closed and viewable here as an archive.

Home Forums Back End Make role see and edit specific pages WORDPRESS

  • This topic is empty.
Viewing 2 posts - 1 through 2 (of 2 total)
  • Author
    Posts
  • #44357
    bastunqk
    Participant

    Hi.
    How to make editors to see and edit only selected pages ?
    Here is how i add new role:


    add_role( 'webmaster', 'уебмастър' );
    /*Add cap*/
    function add_theme_caps() {
    // gets the author role
    $role = get_role( 'webmaster' );

    // This only works, because it accesses the class instance.
    // would allow the author to edit others' posts for current theme only
    $role->add_cap( 'edit_others_posts' );
    $role->add_cap( 'moderate_comments' );
    $role->add_cap( 'upload_files' );
    $role->add_cap( 'edit_posts' );
    $role->add_cap( 'edit_published_posts' );
    $role->add_cap( 'publish_posts' );
    $role->add_cap( 'edit_comment' );
    }
    add_action( 'admin_init', 'add_theme_caps');

    Now how to make them see and edit only specific pages?
    Regards.

    #133351
    bastunqk
    Participant

    Anybody ?

Viewing 2 posts - 1 through 2 (of 2 total)
  • The forum ‘Back End’ is closed to new topics and replies.