Title: Filter posts by author
Last modified: August 21, 2016

---

# Filter posts by author

 *  Resolved [aleksandrk](https://wordpress.org/support/users/aleksandrk/)
 * (@aleksandrk)
 * [12 years, 5 months ago](https://wordpress.org/support/topic/filter-posts-by-author/)
 * Hi,
 * I need to use the plugin to filter posts by author (it’s a multi-author site).
   Is this possible and if so how to do it? or can the functionality be added?
 * Thank you,
    Alex
 * [http://wordpress.org/plugins/query-wrangler/](http://wordpress.org/plugins/query-wrangler/)

Viewing 4 replies - 1 through 4 (of 4 total)

 *  Plugin Author [Jonathan Daggerhart](https://wordpress.org/support/users/daggerhart/)
 * (@daggerhart)
 * [12 years, 5 months ago](https://wordpress.org/support/topic/filter-posts-by-author/#post-4443029)
 * I’ve added the author filter to 1.5rc19. It works according to these parameters:
   [http://codex.wordpress.org/Class_Reference/WP_Query#Author_Parameters](http://codex.wordpress.org/Class_Reference/WP_Query#Author_Parameters).
 * Let me know if you run into any issues with it.
 *  Thread Starter [aleksandrk](https://wordpress.org/support/users/aleksandrk/)
 * (@aleksandrk)
 * [12 years, 5 months ago](https://wordpress.org/support/topic/filter-posts-by-author/#post-4443100)
 * Hi Jonathan,
 * Thank you for the reply and the addition of author parameters to the module. 
   I can see it there. But, I have another question on the matter, is it possible
   to obtain the author id from the page url? I guess, I can’t find the way to introduce
   dynamic arguments into the query. I am trying to use the widget to automatically
   generate posts for the author on whose page the user is.
 * I am also wandering if it’s possible to create query pages dynamically. For example
   $user/test will create a query page for each user. I am very new to wordpress,
   so if this is impossible please just let me know.
 * Thank you for you help, it is very appreciated,
    Alex
 * Note: This is a second edit to the post since I figured out the ‘private’ pages
   question.
 *  Plugin Author [Jonathan Daggerhart](https://wordpress.org/support/users/daggerhart/)
 * (@daggerhart)
 * [12 years, 4 months ago](https://wordpress.org/support/topic/filter-posts-by-author/#post-4443141)
 * Hi alexsandrk,
 * What you’re describing is a contextual filter. This is on my list, but after 
   exposed filters so it may take me a while to get there.
 *  Plugin Author [Jonathan Daggerhart](https://wordpress.org/support/users/daggerhart/)
 * (@daggerhart)
 * [12 years, 2 months ago](https://wordpress.org/support/topic/filter-posts-by-author/#post-4443152)
 * alexsandrk,
 * I think the newest release has a solution you could use for this. It’s not in
   the UI, but it’s the ability to override the WP_Query args using the shortcode.
 * Assuming you have the query created and it’s id is 1, and that you can use PHP
   in your wordpress widgets, you could; create a new Widget that can use php, get
   the global $post object, place the query shortcode into the widget, and dynamically
   alter the arguments with php.
 * Resulting in something like this:
    ` <?php global $post; ?> [query id="1" args
   ="author=<?php print $post->post_author; ?>"]
 * Just a thought. If you’re not too familiar with PHP, this might not be the best
   approach.

Viewing 4 replies - 1 through 4 (of 4 total)

The topic ‘Filter posts by author’ is closed to new replies.

 * ![](https://ps.w.org/query-wrangler/assets/icon-256x256.jpg?rev=3279076)
 * [Query Wrangler](https://wordpress.org/plugins/query-wrangler/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/query-wrangler/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/query-wrangler/)
 * [Active Topics](https://wordpress.org/support/plugin/query-wrangler/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/query-wrangler/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/query-wrangler/reviews/)

 * 4 replies
 * 2 participants
 * Last reply from: [Jonathan Daggerhart](https://wordpress.org/support/users/daggerhart/)
 * Last activity: [12 years, 2 months ago](https://wordpress.org/support/topic/filter-posts-by-author/#post-4443152)
 * Status: resolved