• Hi,

    I have a question, I have many users (Authors) who can log into WordPress admin panel to post their blog entries. But doing so, they all can see each others posts, even though not being able to edit any post but their own’s.

    From users point of view, it is not the best thing in the world to look for your own posts in the list, especially if there are lots of users in the system.

    Same as the Media Taba and the Comment Tab.

    How can I hide them from users other than admin (myself)?

    Plugin would be good. If not, please point me to the relevant Code doc. Thank you.

    regards,
    Will

Viewing 5 replies - 1 through 5 (of 5 total)
  • http://wordpress.org/support/topic/show-only-authors-posts-in-admin-panel-instead-of-all-posts

    Example based on the code i posted there.

    function posts_for_current_author($query) {
    	global $pagenow;
    
    	if( 'edit.php' != $pagenow || !$query->is_admin )
    	    return $query;
    
    	if( !current_user_can( 'manage_options' ) ) {
    		global $user_ID;
    		$query->set('author', $user_ID );
    	}
    	return $query;
    }
    add_filter('pre_get_posts', 'posts_for_current_author');

    Thread Starter relativity98

    (@relativity98)

    Thanks Telos.

    I have read the link above. That was very innformative. Thank once again for the info.

    I am relatively new to WordPress… just wondering for the above scenario, would it be better to have Multisites?

    I want this site to have multi-authors (main purpose is to write posts) similar to other blogging sites for example hubpages etc… from the administrative point of view, the standard version is sufficient right?

    thanks,
    Will

    Thread Starter relativity98

    (@relativity98)

    Hi Telos,

    Where do I insert this code? I am using WP 3.0.1, is it in the admin-functions.php?

    regards,
    Will

    Thread Starter relativity98

    (@relativity98)

    It’s ok. I found the function.php file.

    thanks,
    Will

    Thread Starter relativity98

    (@relativity98)

    Hi Telos,

    I noticed in your previous discussions, a number of members also want to hide the comments and media tabs. Is this doable? Only to show their own comments and photos?

    Also, up the top Mine | All | Published | Draft | Trash can we do something about it? Only to show their own posts?

    Many thanks,
    Will

Viewing 5 replies - 1 through 5 (of 5 total)
  • The topic ‘How to hide other users' posts in admin panel’ is closed to new replies.