Advertisement
Guest User

Untitled

a guest
Dec 19th, 2014
148
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.28 KB | None | 0 0
  1. <?php
  2.  
  3. /** Display only current author posts */
  4. function current_author_posts($link) {
  5. global $post,$current_user;
  6. get_currentuserinfo();
  7. if ($post->post_author == $current_user->ID) {
  8. return $post;
  9. }
  10. return false;
  11. }
  12. add_filter('get_edit_post_link','current_author_posts');
  13.  
  14. ?>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement