WordPress.org

Ready to get started?Download WordPress

Forums

JSON API
get_page_index 5 children only (1 post)

  1. pmercey
    Member
    Posted 2 years ago #

    It seems the bug [Plugin: JSON API] get_page_index returns only five pages is only partly fixed, indeed when looping on the children of a page it returns only 5 pages.

    I temporarily fixed it in json-api/singletons/introspector.php , function attach_child_posts, adding numberpost key in the array below.

    $wp_children = get_posts(array(
    'post_type' => $post->type,
    'post_parent' => $post->id,
    'order' => 'ASC',
    'orderby' => 'menu_order',
    'numberposts' => 100
    ));

    But I am sure it would require a more in-depth fix.

    Thanks for the great plugin anyway :-)

    http://wordpress.org/extend/plugins/json-api/

Topic Closed

This topic has been closed to new replies.

About this Plugin

About this Topic

Tags