offset
-
I would like to implement an ‘infinite scroll’ on the posts.
Is there a way to adjust the params below to achieve that?var response_url = ‘https://example.com/’;
var params = {
json:’get_category_posts’,
category_slug:’science’,
// posted_before: ??
};https://www.ads-software.com/plugins/json-api/
WP_Query supports date_query based and it does understand from ‘before’ param:
before (string/array) – Date to retrieve posts before. Accepts strtotime()-compatible string, or array of ‘year’, ‘month’, ‘day’ values:
The question is how to we tell json-api to use this param in filtering down the posts!
- The topic ‘offset’ is closed to new replies.