Modify url structure for recurring events

Home Forums Calendar Products Events Calendar PRO Modify url structure for recurring events

Viewing 4 posts - 1 through 4 (of 4 total)
  • Author
    Posts
  • #1120321
    Dan
    Participant

    We are using recurring events ( only with date recurrence ). We would need to tinker a bit with the permalinks, as we would need to remove the current behaviour, where /all is appended to the url and /2016-06-06/ is appended for single instances. What we would want to do is the following, assuming that the events has the slug “chicago”:

    slug /events/chicago is generated and displays the single-event.php template
    slug /event/chicago/all is not generated at all or redirects to /events/chicago. slugs for recurrence dates are not generated at all or redirects to /events/chicago.
    We are programmers so any suggestion is welcome

    #1120332
    Dan
    Participant

    I think I was able to achieve what i wanted by removing some filters


    $events_pro = \Tribe__Events__Pro__Main::instance();
    remove_filter( 'post_type_link', array(
    $events_pro->permalink_editor,
    'filter_recurring_event_permalinks',
    ), 10 );
    remove_action( 'tribe_events_pre_get_posts', array( $events_pro, 'pre_get_posts' ) );
    remove_filter( 'wp', array( $events_pro, 'detect_recurrence_redirect' ) );

    #1120377
    Nico
    Member

    Hi Dan,

    Thanks for reaching out to us! And thanks for the follow-up as well, it looks like you have this under control 🙂

    Just be sure to test this extensively, to see if it has some undesired side-effect. Other than that it seems to be a clean workaround!

    Please let me know if there’s anything else I can do for you,
    Best,
    Nico

    #1126778
    Support Droid
    Keymaster

    This topic has not been active for quite some time and will now be closed.

    If you still need assistance please simply open a new topic (linking to this one if necessary)
    and one of the team will be only too happy to help.

Viewing 4 posts - 1 through 4 (of 4 total)
  • The topic ‘Modify url structure for recurring events’ is closed to new replies.