Forums

[resolved] Delete dates added by Event Calendar plugin in Options Theme excerpts (1 post)

  1. rwanito
    Member
    Posted 2 years ago #

    I paste here the solution given to delete dates added in excerpts by Event Calendar :

    The file to modify is inside the plugin: wp-content/plugins/event-calendar/eventcalendar3.php

    The last lines of the page are like that:

    if($ec3->show_event_box)
        add_filter('the_content','ec3_filter_the_content',20);
    
      remove_filter('get_the_excerpt', 'wp_trim_excerpt');
      add_filter('get_the_excerpt', 'ec3_get_the_excerpt');
    
      if($ec3->advanced)
      {
        add_filter('posts_orderby','ec3_filter_posts_orderby',11);
        // In advanced mode, exclude events from the archive.
        add_filter('getarchives_join', 'ec3_filter_getarchives_join');
        add_filter('getarchives_where','ec3_filter_getarchives_where');
      }
    }

    Commenting this line:
    add_filter('the_posts', 'ec3_filter_the_posts');
    prevent any dates to be written anywhere within the post (both excerpt and full post)

    But, because you can turn off in the plugin options dates in the full post, you just need to comment this line:
    add_filter('get_the_excerpt', 'ec3_get_the_excerpt');
    to get rid of dates in the excerpts of the various blocks of Options Theme.

    Found here :
    http://themehybrid.com/support/topic/delete-dates-added-by-event-calendar-plugin-in-options-theme-excerpts

Topic Closed

This topic has been closed to new replies.

About this Topic

Tags