Support » Plugin: Simpul Events by Esotech » Calender only showed 10 events (default posts/page). Fixed it, here's how

  • Hi,
    first of all – thank you for this plugin. It works nicely (see it in action @
    However, I wrecked my brain why it would only show 10 events. It turns out, the WP_query you use, used the selected number of posts per page.
    You can adjust this at Settings > messages. It shows the default value ’10’. You can just set this to all, but that will mess your site up if you’re working with pagination.

    The fix is as follows: in simpulevents.php, in the root folder of the plugin, find this bit:

    $args = array('post_type' => 'events',
    						'post_status' => 'published',
    						'order_by' => 'meta_value',
    						'meta_key' => $this->meta_prefix . "date_begin",
    						'order' => 'ASC',

    Just add an extra parameter of the arguments:
    'posts_per_page' => -1,
    This will override the max 10 posts bit, and gets all the posts (events). The parameter used to be ‘showposts’ btw, but that is deprecated.

    Hope this helps somebody, and perhaps it’s good stuff for an update?

Viewing 1 replies (of 1 total)
  • Plugin Author geilt


    Thanks for the update. I will add a option in the Calendar menu to modify posts per page as well. You are correct in that it uses the blogs default.

    Couple other fixes to come as well.

Viewing 1 replies (of 1 total)
  • The topic ‘Calender only showed 10 events (default posts/page). Fixed it, here's how’ is closed to new replies.