Support » Fixing WordPress » Admin/manage: can I hide other peoples posts?

  • Hi,

    I would really like it if only the ‘logged in user (non-admin)’ could see their posts in managed instead of everyone elses as well.

    Is there a way to do this or a plug-in to do this?

    Thanks

Viewing 2 replies - 1 through 2 (of 2 total)
  • torio

    (@torio)

    I am looking for this same answer and it seems to be a big secret? Let me know if you get the answer

    I had to do the same thing for a small internal project.

    This is the code I wrote in wp-admin/edit.php right after “foreach($posts_columns as $column_name=>$column_display_name)”:

    <begin>
    $post_author_data = get_userdata($post->post_author);

    if ($wpdb->escape($_COOKIE[USER_COOKIE]) == $post_author_data->user_login || $wpdb->escape($_COOKIE[USER_COOKIE]) == “admin”) {

    switch code

    }
    <end>

    Now the logged in user will only see their own posts. The admin user will also be able to see all posts (as long as the admin username is ‘admin’).

    Regards,
    Avinesh Bangar

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘Admin/manage: can I hide other peoples posts?’ is closed to new replies.