Viewing 8 replies - 1 through 8 (of 8 total)
  • Plugin Author dFactory

    (@dfactory)

    It appears several times in different event pages I guess, not only category.

    I assume you want event ocurrences to be displayed in single event only. Am I right?

    Thread Starter mahii-conception

    (@mahii-conception)

    Hi,

    Yes indeed.

    Thanks

    Thread Starter mahii-conception

    (@mahii-conception)

    How can I do ?

    Plugin Author dFactory

    (@dfactory)

    There are multiple ways.

    For example replace em_display_single_event_date() function in your theme
    or hook into em_single_event_meta_start action to display recurriong events intead of signle event date.

    In any case you’d need to take a look at the plugin code and functions used to display event dates in a theme.

    Thread Starter mahii-conception

    (@mahii-conception)

    I can just add

    function em_display_single_event_date()
    {
    // is recurring?
    if (em_is_recurring())
    {
    // display occurrences date
    em_display_event_occurrences();
    }
    else
    {
    // display event date
    em_display_event_date();
    }
    }

    In the function.php of my theme to override it ?
    And then modifiy the fonction ?

    Plugin Author dFactory

    (@dfactory)

    You can copy this function to your theme functions.php and modify to display occurences always.

    Pls, check if it does the trick.

    I think the problem is if I’ve got a recurring event for say, a few years, that clicking on the occurrence then lists out all those dates. Looking at the function path neither em_display_single_event_date nor em_display_event_occurrences seem to have knowledge of what day the user clicked on. I’d like the recurring event to only display the date that was selected from the main calendar. How can I accomplish this? Or just point me to the right function? Thanks!

    Plugin Author dFactory

    (@dfactory)

    There are some more functions, but not realy used in the plugin yet:

    em_get_active_occurrence($post_id = 0) – this would give you a currently running event (by $post_id) occurence – like in the radio “On air”

    em_get_next_occurrence($post_id = 0) – and this can be used to have the next occurence of a certain event.

    If that will not be enough in this case you may try something more general:

    em_get_occurrences($post_id = 0, $period = ‘all’, $orderby = ‘asc’, $limit = 0)

    to get event occurences in a more flexible way. Important parameter here might be the “period”. If you change that from “all” to “future” you’d ge all future ocurrences of an event.

    To get some more details about avaiable parameters please check the core-functions.php in events-maker -> includes folder.

    Hope this helps.

    Regards,
    Bartosz / dfactory

Viewing 8 replies - 1 through 8 (of 8 total)
  • The topic ‘Recurent event’ is closed to new replies.