Support » Plugin: Event Organiser » eo_get_the_start not consistent with recurring events

  • Resolved superbiaweb

    (@superbiaweb)


    Thanks for developing a great events plugin. Most are way too complex and are difficult to customise.

    I’m using eo_get_the_start() on the single template and on recurring events it returns the start date from a different, seemingly random occurrence of the event every time you save the event in the admin. The weird thing is that it worked fine on my development setup but broke when I put it on the staging server.

    Is this a limitation of eo_get_the_start() on the single template? Should I be checking if the event is recurring and then using eo_get_schedule_start() instead?

    Thanks!

    Dylan

    https://wordpress.org/plugins/event-organiser/

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

    (@stephenharris)

    Hi Dylan,

    I’m glad you like the plug-in :).

    Yes, you should avoid using eo_get_the_start() on the single event page. There is no “one date” for an event on the single event page as the same page is used for all dates. However, as you noted you can use eo_get_schedule_start() (see codex).

    That function will effectively behave the same as eo_get_the_start() for single occurrence events, so there is no need to check if the event is recurring or not.

    Thanks Stephen.

    Okay cool, it’s all working great now.

    Cheers,

    Dylan

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘eo_get_the_start not consistent with recurring events’ is closed to new replies.