Reputation: 24635
I need to get archives of one author and exlude all others, Wordpress wp get archives() doesn't have that kind of filter. How can I fitler all other others except one author from archives?
http://codex.wordpress.org/Template_Tags/wp_get_archives
<?php wp_get_archives('type=monthly'); ?>
Upvotes: 4
Views: 1944
Reputation: 1048
Just off the top of my head:
get_posts(array('author_name' => 'the_authors_name'))
You don't get anything preformatted like from wp_get_archives
, just the list of posts, but you get the posts by author. If you need to do more fancy things or want to run a WP Loop you can do a custom WP_Query
object as well.
Upvotes: 4