• Resolved Cory Hughart

    (@cr0ybot)


    Using the tribe_get_events() function, passing ‘posts_per_page’ as an argument with any number is ignored, and the function always returns the default number of events per page.

    In /src/Tribe/Query.php, starting on line 1121, the getEvents() method is using wp_parse_args() and overriding $args with $defaults. Since ‘posts_per_page’ is set in $defaults, the same property in $args is being overridden.

    Using the ‘posts_per_page’ setting is the first thing mentioned in the documentation, but it doesn’t work as described.

    I am handling this via a counter variable, but I thought I’d bring it to your attention.

    The page I need help with: [log in to see the link]

  • The topic ‘tribe_get_events() overrides ‘posts_per_page’’ is closed to new replies.