• Resolved GoodUtopian

    (@goodutopian)


    HI, I’m trying to display a list of the 5 most recent events using shortcodes:

    Recent events:
    [eo_events event_end_before=”today” numberposts=”5″]

    But this is showing the FIRST five events in chronological order, when what I want is the most recent five events in reverse chron order. I can’t figure out how to do this — is there a way?

    Thank you!
    A

    https://www.ads-software.com/extend/plugins/event-organiser/

Viewing 6 replies - 1 through 6 (of 6 total)
  • Plugin Author Stephen Harris

    (@stephenharris)

    So you want to show past events, but only the last 5?

    Try

    [eo_events event_end_before="today" numberposts="5" order="DESC"]

    By default it sorts by the start date, so you may wish to sort by end date. See the docs for more information.

    Hope that helps!

    Thread Starter GoodUtopian

    (@goodutopian)

    Thanks so much for responding, but this doesn’t work. When I did this, it gave me all recent posts in ascending order (starting with the date farthest in the past). I copied the code directly. Any other thoughts?
    Thanks!
    Anna

    That’s odd. Its definitely working for me. What happens if you change “DESC” to “ASC” – does the order change? If not, it sounds like maybe a plug-in interfering with the query – could you try disabling all other plug-ins and switching your theme to TwentyEleven/Twelve just to check ?

    Thread Starter GoodUtopian

    (@goodutopian)

    Thank you! I cleaned up my plug-ins, and it works perfectly. Much appreciated!

    Which was the offending plug-in? I can take a look, and let the plug-in author know – so others won’t have the same problem!

    Thread Starter GoodUtopian

    (@goodutopian)

    you know, i wasn’t scientific about it — i had a couple that were deactivated, which i deleted, and i had a couple that were active but i wasn’t using them — i think the latter were jetpack and something about parallel loading that i don’t recall ever installing ….

    next time, i’ll be more methodical, so i can be of help!

Viewing 6 replies - 1 through 6 (of 6 total)
  • The topic ‘Show 5 most recent events in reverse order?’ is closed to new replies.