Previous & Next on MEC

I’ve been unable to successfully create ( <- PREV ) & ( NEXT -> ) toggles that actually go to the previous and next events. Any suggestion on how to work around published dates and use mec_start_date ?

Hello @splaquet,

Thanks for writing in! Are you adding the page navigation to your single layout? It may not work if you have a Looper provider. We would be happy to double-check your custom layout if we can log in. You can create a secure note in your next reply with the following info:
– Link to your site
– WP login URL
– WP username
– WP password
– WP Administrator Role
– Confirmation that we can access and make changes to your site

To know how to create a secure note, please check this out: How The Forum Works

image

Best Regards.

I am able to sort the events correctly on the front end, so I’d like to believe it’s possible… hopefully that’s the case!

here’s the front end event page:
https://dev.iwfct.org/mec-programs/

Hello @splaquet,

The Prev and Next or the Post Navigation element works for a single layout.

The numbered pages or the Post Pagination element will only work on any archive layouts. You cannot use this element on a normal page like what you have right now. You can edit your MEC Programs page and save this as a template and create an MEC archive layout instead, where you can use the Post Pagination element.

Hope this helps.

My apologies, but maybe I didn’t explain this clearly. In my previous post, I was trying to show the calendar entries properly sorted on the archive page. You have to click into each date to see the prev/next and how they’re not in order.

this page IS an archive page and it’s sorted correctly
https://dev.iwfct.org/mec-programs/

the prev/next page IS a single layout
https://dev.iwfct.org/events/2026-iwfct-march-informal-luncheon-gatherings-new-haven-ct/

as mentioned in the secure note, the edit link to the single page is:
https://dev.iwfct.org/cornerstone/edit/2225

Hey @splaquet,

Now, I got what you need. You can use this query instead:
image

Less than mec_start_date of the current post for the previous event, while using the greater than mec_start_date of the current post for the next event.

Check the demo now: https://dev.iwfct.org/events/2026-iwfct-march-informal-luncheon-gatherings-westport-ct/