Title: get_posts with variable after doesn&#039;t work
Last modified: August 22, 2016

---

# get_posts with variable after doesn't work

 *  [byakuya68](https://wordpress.org/support/users/byakuya68/)
 * (@byakuya68)
 * [11 years, 9 months ago](https://wordpress.org/support/topic/get_posts-with-variable-after-doesnt-work/)
 * Hi,
 * The get_posts method doesn’t work with after parameter. For example with this
   URL : [http://www.example.com/?json=get_posts&after=20140806&posts_per_page=-1](http://www.example.com/?json=get_posts&after=20140806&posts_per_page=-1),
   I get all the posts before 2014.08.06 but nothing after..
 * It have tested with before parameter, and I have exactly the same results. It
   seams that after variable behave exactly like before variable.
 * Can you give a workaround or even the file to correct this because I am pretty
   sure it is a bug, like a copy/paste that have been done during development.
 * Regards
 * [https://wordpress.org/plugins/json-api/](https://wordpress.org/plugins/json-api/)

The topic ‘get_posts with variable after doesn't work’ is closed to new replies.

 * ![](https://s.w.org/plugins/geopattern-icon/json-api.svg)
 * [JSON API](https://wordpress.org/plugins/json-api/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/json-api/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/json-api/)
 * [Active Topics](https://wordpress.org/support/plugin/json-api/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/json-api/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/json-api/reviews/)

 * 0 replies
 * 1 participant
 * Last reply from: [byakuya68](https://wordpress.org/support/users/byakuya68/)
 * Last activity: [11 years, 9 months ago](https://wordpress.org/support/topic/get_posts-with-variable-after-doesnt-work/)
 * Status: not resolved