How to show Author’s Posts Only in Author Dashboard in WordPress?

2090

How are you? I hope all of you are fine. I’m also fine for your blessings. Today I will share with you “How to show Author’s Posts Only in Author Dashboard in WordPress?“.

How To Limit The WordPress Posts Screen To Only Show Authors Their Own Posts?

wordpress-dashboard

Today I will discuss with which subject, then how to show tunes only author on the Admin tune list?? What is the matter?? After logging in, in Techtunes, if you click in all tunes of the dashboard, then what does it show, it shows only author tunes. All tunes of Techtunes doesn’t show, only shows your tune. Today we will discuss about this subject.

If there are several author in your blog, then this is very important because each author will see their tunes in the only admin tune list.

Through an easy code, you can do this work. Paste following code in function file (functions.php) of your theme. Save that file. After saving, only author can see his tune in the Admin tune list.

function mypo_parse_query_useronly($wp_query) {
    if (strpos($_SERVER[ 'REQUEST_URI' ], '/wp-admin/edit.php') !== false) {
        if (!current_user_can('level_10')) {
            global $current_user;
            $wp_query->set('author', $current_user->id);
        }
    }
}
add_filter('parse_query', 'mypo_parse_query_useronly');
?>

I hope this tune will work for you. Thank you for reading this article. If there is any mistake, then forgive me. If you face any problem, then don’t forget to comment. If you think the article is beneficial then obviously share it.