/**
  * Constructor function. a.k.a. Let's get this party started!
  *
  * @param string $plugin_file file path.
  */
 public function __construct($plugin_file)
 {
     self::$plugin_file = $plugin_file;
     if (!class_exists('TribeCommonLibraries')) {
         require_once dirname(self::$plugin_file) . '/vendor/tribe-common-libraries/tribe-common-libraries.class.php';
     }
     TribeCommonLibraries::register('tribe-pue-client', '1.5', dirname(self::$plugin_file) . '/vendor/pue-client/pue-client.php');
     add_action('tribe_helper_activation_complete', array($this, 'load_plugin_update_engine'));
     register_activation_hook(self::$plugin_file, array($this, 'register_uninstall_hook'));
 }
 private function __construct()
 {
     $this->pluginDir = trailingslashit(basename(dirname(__FILE__)));
     $this->pluginPath = trailingslashit(dirname(__FILE__));
     $this->pluginUrl = plugins_url() . '/' . $this->pluginDir;
     $this->pluginSlug = 'events-calendar-pro';
     require_once 'lib/tribe-date-series-rules.class.php';
     require_once 'lib/tribe-ecp-custom-meta.class.php';
     require_once 'lib/tribe-events-recurrence-meta.class.php';
     require_once 'lib/tribe-recurrence.class.php';
     require_once 'lib/widget-calendar.class.php';
     require_once 'template-tags.php';
     require_once 'lib/tribe-presstrends-events-calendar-pro.php';
     // Tribe common resources
     require_once 'vendor/tribe-common-libraries/tribe-common-libraries.class.php';
     TribeCommonLibraries::register('pue-client', '1.2', $this->pluginPath . 'vendor/pue-client/pue-client.php');
     TribeCommonLibraries::register('advanced-post-manager', '1.0.5', $this->pluginPath . 'vendor/advanced-post-manager/tribe-apm.php');
     //TribeCommonLibraries::register( 'tribe-support', '0.1', $this->pluginPath . 'vendor/tribe-support/tribe-support.class.php' );
     // Next Event Widget
     require_once 'lib/widget-featured.class.php';
     add_action('init', array($this, 'init'), 10);
     add_action('init', array($this, 'enqueue_resources'));
     add_action('tribe_after_location_details', array($this, 'add_google_map_preview'));
     add_action('tribe_tec_template_chooser', array($this, 'do_ical_template'));
     add_filter('tribe_settings_do_tabs', array($this, 'add_settings_tabs'));
     add_filter('tribe_current_events_page_template', array($this, 'select_venue_template'));
     add_filter('tribe_help_tab_getting_started_text', array($this, 'add_help_tab_getting_started_text'));
     add_filter('tribe_help_tab_enb_content', array($this, 'add_help_tab_enb_text'));
     add_filter('tribe_events_template_single-venue.php', array($this, 'load_venue_template'));
     add_action('widgets_init', array($this, 'pro_widgets_init'), 100);
     add_action('wp_loaded', array($this, 'allow_cpt_search'));
     add_action('plugin_row_meta', array($this, 'addMetaLinks'), 10, 2);
     add_filter('get_delete_post_link', array($this, 'adjust_date_on_recurring_event_trash_link'), 10, 2);
     add_action('admin_footer', array($this, 'addDeleteDialogForRecurringEvents'));
     // Load organizer and venue editors
     add_action('admin_menu', array($this, 'addVenueAndOrganizerEditor'));
     add_action('tribe_venue_table_top', array($this, 'displayEventVenueDropdown'));
     add_action('tribe_organizer_table_top', array($this, 'displayEventOrganizerDropdown'));
     add_action('tribe_helper_activation_complete', array($this, 'helpersLoaded'));
     add_filter('tribe_promo_banner', array($this, 'tribePromoBannerPro'));
     add_filter('tribe_help_tab_forums_url', array($this, 'helpTabForumsLink'));
     add_action('plugin_action_links_' . plugin_basename(__FILE__), array($this, 'addLinksToPluginActions'));
 }
 private function __construct()
 {
     self::$tribe_registered_plugins = array();
     add_action('plugins_loaded', array($this, 'activate_plugins'), 999);
 }
 /**
  * Class constructor.
  */
 private function __construct()
 {
     $this->pluginDir = trailingslashit(basename(dirname(__FILE__)));
     $this->pluginPath = trailingslashit(dirname(__FILE__));
     $this->pluginUrl = WP_PLUGIN_URL . '/' . $this->pluginDir;
     $this->pluginSlug = 'events-calendar-pro';
     $this->loadTextDomain();
     $this->weekSlug = sanitize_title(__('week', 'tribe-events-calendar-pro'));
     $this->photoSlug = sanitize_title(__('photo', 'tribe-events-calendar-pro'));
     $this->daySlug = sanitize_title(__('day', 'tribe-events-calendar-pro'));
     $this->todaySlug = sanitize_title(__('today', 'tribe-events-calendar-pro'));
     require_once 'lib/tribe-pro-template-factory.class.php';
     require_once 'lib/tribe-date-series-rules.class.php';
     require_once 'lib/tribe-ecp-custom-meta.class.php';
     require_once 'lib/tribe-events-recurrence-meta.class.php';
     require_once 'lib/tribe-recurrence.class.php';
     require_once 'lib/widget-venue.class.php';
     require_once 'lib/tribe-mini-calendar.class.php';
     require_once 'lib/widget-countdown.class.php';
     require_once 'lib/widget-calendar.class.php';
     require_once 'lib/template-classes/day.php';
     require_once 'lib/template-classes/map.php';
     require_once 'lib/template-classes/photo.php';
     require_once 'lib/template-classes/single-organizer.php';
     require_once 'lib/template-classes/single-venue.php';
     require_once 'lib/template-classes/week.php';
     require_once 'public/template-tags/general.php';
     require_once 'public/template-tags/week.php';
     require_once 'public/template-tags/venue.php';
     require_once 'public/template-tags/widgets.php';
     require_once 'lib/tribe-geoloc.class.php';
     require_once 'lib/meta-pro.php';
     //iCal
     require_once 'lib/tribe-ical.class.php';
     TribeiCal::init();
     // Tribe common resources
     require_once 'vendor/tribe-common-libraries/tribe-common-libraries.class.php';
     TribeCommonLibraries::register('advanced-post-manager', '1.0.5', $this->pluginPath . 'vendor/advanced-post-manager/tribe-apm.php');
     TribeCommonLibraries::register('related-posts', '1.1', $this->pluginPath . 'vendor/tribe-related-posts/tribe-related-posts.class.php');
     //TribeCommonLibraries::register( 'tribe-support', '0.1', $this->pluginPath . 'vendor/tribe-support/tribe-support.class.php' );
     add_action('tribe_helper_activation_complete', array($this, 'helpersLoaded'));
     add_action('init', array($this, 'init'), 10);
     add_action('admin_enqueue_scripts', array($this, 'admin_enqueue_scripts'));
     add_action('wp_enqueue_scripts', array($this, 'enqueue_pro_scripts'), 8);
     add_action('wp_enqueue_scripts', array($this, 'enqueue_styles'));
     add_filter('tribe_settings_do_tabs', array($this, 'add_settings_tabs'));
     add_filter('generate_rewrite_rules', array($this, 'add_routes'), 11);
     add_filter('tribe_events_buttons_the_buttons', array($this, 'add_view_buttons'));
     add_filter('tribe_events_pre_get_posts', array($this, 'pre_get_posts'));
     add_filter('tribe_enable_recurring_event_queries', '__return_true', 10, 1);
     add_filter('body_class', array($this, 'body_class'));
     add_filter('tribe_current_events_page_template', array($this, 'select_page_template'));
     add_filter('tribe_current_events_template_class', array($this, 'get_current_template_class'));
     add_filter('tribe_events_template_paths', array($this, 'template_paths'));
     add_filter('tribe_events_template_class_path', array($this, 'template_class_path'));
     add_filter('tribe_help_tab_getting_started_text', array($this, 'add_help_tab_getting_started_text'));
     add_filter('tribe_help_tab_introtext', array($this, 'add_help_tab_intro_text'));
     add_filter('tribe_help_tab_forumtext', array($this, 'add_help_tab_forumtext'));
     // add_filter( 'tribe_events_template_single-venue.php', array( $this, 'load_venue_template' ) );
     add_action('widgets_init', array($this, 'pro_widgets_init'), 100);
     add_action('wp_loaded', array($this, 'allow_cpt_search'));
     add_action('plugin_row_meta', array($this, 'addMetaLinks'), 10, 2);
     add_filter('get_delete_post_link', array($this, 'adjust_date_on_recurring_event_trash_link'), 10, 2);
     add_action('admin_footer', array($this, 'addDeleteDialogForRecurringEvents'));
     add_filter('tribe_get_events_title', array($this, 'reset_page_title'));
     add_filter('tribe_events_add_title', array($this, 'maybeAddEventTitle'), 10, 3);
     add_filter('tribe_promo_banner', array($this, 'tribePromoBannerPro'));
     add_filter('tribe_help_tab_forums_url', array($this, 'helpTabForumsLink'));
     add_action('plugin_action_links_' . plugin_basename(__FILE__), array($this, 'addLinksToPluginActions'));
     add_filter('tribe_events_before_html', array($this, 'events_before_html'), 10);
     // add custom fields to "the_meta" on single event template
     add_filter('tribe_events_single_event_the_meta_addon', array($this, 'single_event_the_meta_addon'), 10, 2);
     add_filter('tribe_events_single_event_meta_group_template_keys', array($this, 'single_event_meta_group_template_keys'), 10);
     add_filter('tribe_events_single_event_meta_template_keys', array($this, 'single_event_meta_template_keys'), 10);
     add_filter('tribe_event_meta_venue_name', array('Tribe_Register_Meta_Pro', 'venue_name'), 10, 2);
     add_filter('tribe_event_meta_organizer_name', array('Tribe_Register_Meta_Pro', 'organizer_name'), 10, 2);
     add_filter('tribe_events_single_event_the_meta_group_venue', array($this, 'single_event_the_meta_group_venue'), 10, 2);
     // add related events to single event view
     add_action('tribe_events_single_event_after_the_meta', 'tribe_single_related_events');
     // add_action( 'tribe_events_single_event_meta_init', array( $this, 'single_event_meta_init'), 10, 4);
     // see function tribe_convert_units( $value, $unit_from, $unit_to )
     add_filter('tribe_convert_kms_to_miles_ratio', array($this, 'kms_to_miles_ratio'));
     add_filter('tribe_convert_miles_to_kms_ratio', array($this, 'miles_to_kms_ratio'));
     /* Setup Tribe Events Bar */
     add_filter('tribe-events-bar-views', array($this, 'setup_weekview_in_bar'), 10, 1);
     add_filter('tribe-events-bar-views', array($this, 'setup_dayview_in_bar'), 15, 1);
     add_filter('tribe-events-bar-views', array($this, 'setup_photoview_in_bar'), 30, 1);
     add_filter('tribe_events_ugly_link', array($this, 'ugly_link'), 10, 3);
     add_filter('tribe_events_getLink', array($this, 'get_link'), 10, 4);
     add_filter('tribe-events-bar-date-search-default-value', array($this, 'maybe_setup_date_in_bar'));
     add_filter('tribe_bar_datepicker_caption', array($this, 'setup_datepicker_label'), 10, 1);
     add_action('tribe_events_after_the_title', array($this, 'add_recurring_occurance_setting_to_list'));
     add_filter('tribe_get_day_link', array($this, 'add_empty_date_dayview_link'), 10, 2);
     /* AJAX for loading day view */
     add_action('wp_ajax_tribe_event_day', array($this, 'wp_ajax_tribe_event_day'));
     add_action('wp_ajax_nopriv_tribe_event_day', array($this, 'wp_ajax_tribe_event_day'));
     /* AJAX for loading photo view */
     add_action('wp_ajax_tribe_photo', array($this, 'wp_ajax_tribe_photo'));
     add_action('wp_ajax_nopriv_tribe_photo', array($this, 'wp_ajax_tribe_photo'));
     /* AJAX for loading week view */
     add_action('wp_ajax_tribe_week', array($this, 'wp_ajax_tribe_week'));
     add_action('wp_ajax_nopriv_tribe_week', array($this, 'wp_ajax_tribe_week'));
     add_filter('tribe_events_pre_get_posts', array($this, 'setup_hide_recurrence_in_query'));
     add_filter('wp', array($this, 'detect_recurrence_redirect'));
     add_filter('tribe_events_register_venue_type_args', array($this, 'addSupportsThumbnail'), 10, 1);
     add_filter('tribe_events_register_organizer_type_args', array($this, 'addSupportsThumbnail'), 10, 1);
     // filter the query sql to get the recurrence end date
     add_filter('tribe_events_query_posts_joins', array($this, 'posts_join'));
     add_filter('tribe_events_query_posts_fields', array($this, 'posts_fields'));
     add_filter('tribe_events_query_end_date_column', array($this, 'end_date_column'));
 }
Beispiel #5
0
 /**
  * Class constructor.
  */
 private function __construct()
 {
     $this->pluginDir = trailingslashit(basename(dirname(__FILE__)));
     $this->pluginPath = trailingslashit(dirname(__FILE__));
     $this->pluginUrl = plugins_url($this->pluginDir);
     $this->pluginSlug = 'events-calendar-pro';
     $this->loadTextDomain();
     $this->weekSlug = sanitize_title(__('week', 'tribe-events-calendar-pro'));
     $this->photoSlug = sanitize_title(__('photo', 'tribe-events-calendar-pro'));
     require_once $this->pluginPath . 'lib/tribeeventspro-schemaupdater.php';
     require_once $this->pluginPath . 'lib/tribe-pro-template-factory.class.php';
     require_once $this->pluginPath . 'lib/tribe-date-series-rules.class.php';
     require_once $this->pluginPath . 'lib/tribe-ecp-custom-meta.class.php';
     require_once $this->pluginPath . 'lib/tribe-events-recurrence-meta.class.php';
     require_once $this->pluginPath . 'lib/tribeeventspro-recurrenceseriessplitter.php';
     require_once $this->pluginPath . 'lib/tribeeventspro-recurrenceinstance.php';
     require_once $this->pluginPath . 'lib/tribe-recurrence.class.php';
     require_once $this->pluginPath . 'lib/tribeeventspro-recurrencepermalinks.php';
     require_once $this->pluginPath . 'lib/widget-venue.class.php';
     require_once $this->pluginPath . 'lib/tribe-mini-calendar.class.php';
     require_once $this->pluginPath . 'lib/widget-countdown.class.php';
     require_once $this->pluginPath . 'lib/widget-calendar.class.php';
     require_once $this->pluginPath . 'lib/template-classes/map.php';
     require_once $this->pluginPath . 'lib/template-classes/photo.php';
     require_once $this->pluginPath . 'lib/template-classes/single-organizer.php';
     require_once $this->pluginPath . 'lib/template-classes/single-venue.php';
     require_once $this->pluginPath . 'lib/template-classes/week.php';
     require_once $this->pluginPath . 'public/template-tags/general.php';
     require_once $this->pluginPath . 'public/template-tags/week.php';
     require_once $this->pluginPath . 'public/template-tags/venue.php';
     require_once $this->pluginPath . 'public/template-tags/widgets.php';
     require_once $this->pluginPath . 'lib/tribe-geoloc.class.php';
     require_once $this->pluginPath . 'lib/EmbeddedMaps.php';
     require_once $this->pluginPath . 'lib/SingleEventMeta.php';
     require_once $this->pluginPath . 'lib/Mini_Calendar_Shortcode.php';
     if (TribeEventsPro_SchemaUpdater::update_required()) {
         add_action('admin_init', array('TribeEventsPro_SchemaUpdater', 'init'), 10, 0);
     }
     // Tribe common resources
     TribeCommonLibraries::register('advanced-post-manager', '1.0.5', $this->pluginPath . 'vendor/advanced-post-manager/tribe-apm.php');
     add_action('tribe_helper_activation_complete', array($this, 'helpersLoaded'));
     add_action('init', array($this, 'init'), 10);
     add_action('tribe_events_enqueue', array($this, 'admin_enqueue_scripts'));
     add_action('tribe_venues_enqueue', array($this, 'admin_enqueue_scripts'));
     add_action('wp_enqueue_scripts', array($this, 'enqueue_pro_scripts'), 8);
     add_action('wp_enqueue_scripts', array($this, 'enqueue_styles'));
     add_action('tribe_settings_do_tabs', array($this, 'add_settings_tabs'));
     add_filter('tribe_settings_tab_fields', array($this, 'filter_settings_tab_fields'), 10, 2);
     add_filter('generate_rewrite_rules', array($this, 'add_routes'), 11);
     add_action('tribe_events_parse_query', array($this, 'parse_query'));
     add_action('tribe_events_pre_get_posts', array($this, 'pre_get_posts'));
     add_filter('tribe_enable_recurring_event_queries', '__return_true', 10, 1);
     add_filter('body_class', array($this, 'body_class'));
     add_filter('tribe_current_events_page_template', array($this, 'select_page_template'));
     add_filter('tribe_current_events_template_class', array($this, 'get_current_template_class'));
     add_filter('tribe_events_template_paths', array($this, 'template_paths'));
     add_filter('tribe_events_template_class_path', array($this, 'template_class_path'));
     add_filter('tribe_help_tab_getting_started_text', array($this, 'add_help_tab_getting_started_text'));
     add_filter('tribe_help_tab_introtext', array($this, 'add_help_tab_intro_text'));
     add_filter('tribe_help_tab_forumtext', array($this, 'add_help_tab_forumtext'));
     add_action('widgets_init', array($this, 'pro_widgets_init'), 100);
     add_action('wp_loaded', array($this, 'allow_cpt_search'));
     add_action('plugin_row_meta', array($this, 'addMetaLinks'), 10, 2);
     add_filter('tribe_get_events_title', array($this, 'reset_page_title'), 10, 2);
     add_filter('tribe_events_title_tag', array($this, 'maybeAddEventTitle'), 10, 3);
     add_filter('tribe_help_tab_forums_url', array($this, 'helpTabForumsLink'));
     add_action('plugin_action_links_' . plugin_basename(__FILE__), array($this, 'addLinksToPluginActions'));
     add_filter('tribe_events_before_html', array($this, 'events_before_html'), 10);
     // add custom fields to "the_meta" on single event template
     add_filter('tribe_events_single_event_the_meta_addon', array($this, 'single_event_the_meta_addon'), 10, 2);
     add_filter('tribe_events_single_event_meta_group_template_keys', array($this, 'single_event_meta_group_template_keys'), 10);
     add_filter('tribe_events_single_event_meta_template_keys', array($this, 'single_event_meta_template_keys'), 10);
     add_filter('tribe_event_meta_venue_name', array('TribeEventsPro_SingleEventMeta', 'venue_name'), 10, 2);
     add_filter('tribe_event_meta_organizer_name', array('TribeEventsPro_SingleEventMeta', 'organizer_name'), 10, 2);
     add_filter('tribe_events_single_event_the_meta_group_venue', array($this, 'single_event_the_meta_group_venue'), 10, 2);
     $this->enable_recurring_info_tooltip();
     add_action('tribe_events_before_the_grid', array($this, 'disable_recurring_info_tooltip'), 10, 0);
     add_action('tribe_events_after_the_grid', array($this, 'enable_recurring_info_tooltip'), 10, 0);
     add_action('tribe_events_single_event_after_the_meta', array($this, 'register_related_events_view'));
     // see function tribe_convert_units( $value, $unit_from, $unit_to )
     add_filter('tribe_convert_kms_to_miles_ratio', array($this, 'kms_to_miles_ratio'));
     add_filter('tribe_convert_miles_to_kms_ratio', array($this, 'miles_to_kms_ratio'));
     /* Setup Tribe Events Bar */
     add_filter('tribe-events-bar-views', array($this, 'setup_weekview_in_bar'), 10, 1);
     add_filter('tribe-events-bar-views', array($this, 'setup_photoview_in_bar'), 30, 1);
     add_filter('tribe_events_ugly_link', array($this, 'ugly_link'), 10, 3);
     add_filter('tribe_events_getLink', array($this, 'get_link'), 10, 4);
     add_filter('tribe_bar_datepicker_caption', array($this, 'setup_datepicker_label'), 10, 1);
     add_action('tribe_events_after_the_title', array($this, 'add_recurring_occurance_setting_to_list'));
     add_filter('tribe_is_ajax_view_request', array($this, 'is_pro_ajax_view_request'), 10, 2);
     add_action('tribe_events_pre_get_posts', array($this, 'setup_hide_recurrence_in_query'));
     add_filter('wp', array($this, 'detect_recurrence_redirect'));
     add_filter('template_redirect', array($this, 'filter_canonical_link_on_recurring_events'), 10, 1);
     $this->permalink_editor = apply_filters('tribe_events_permalink_editor', new TribeEventsPro_RecurrencePermalinks());
     add_filter('post_type_link', array($this->permalink_editor, 'filter_recurring_event_permalinks'), 10, 4);
     add_filter('tribe_events_register_venue_type_args', array($this, 'addSupportsThumbnail'), 10, 1);
     add_filter('tribe_events_register_organizer_type_args', array($this, 'addSupportsThumbnail'), 10, 1);
     // filter the query sql to get the recurrence end date
     add_filter('tribe_events_query_posts_joins', array($this, 'posts_join'));
     add_filter('tribe_events_query_posts_fields', array($this, 'posts_fields'));
 }
 /**
  * Class constructor
  * Sets all the class vars up and such
  *
  * @author Nick Ciske
  * @since 1.0
  */
 private function __construct()
 {
     $tec = TribeEvents::instance();
     // Load multisite defaults
     if (is_multisite()) {
         $tribe_community_events_mu_defaults = array();
         if (file_exists(WP_CONTENT_DIR . '/tribe-events-mu-defaults.php')) {
             include WP_CONTENT_DIR . '/tribe-events-mu-defaults.php';
         }
         self::$tribeCommunityEventsMuDefaults = apply_filters('tribe_community_events_mu_defaults', $tribe_community_events_mu_defaults);
     }
     // get options
     $this->defaultStatus = $this->getOption('defaultStatus');
     $this->allowAnonymousSubmissions = $this->getOption('allowAnonymousSubmissions');
     $this->allowUsersToEditSubmissions = $this->getOption('allowUsersToEditSubmissions');
     $this->allowUsersToDeleteSubmissions = $this->getOption('allowUsersToDeleteSubmissions');
     $this->trashItemsVsDelete = $this->getOption('trashItemsVsDelete');
     $this->useVisualEditor = $this->getOption('useVisualEditor');
     $this->eventsPerPage = $this->getOption('eventsPerPage', 10);
     $this->eventListDateFormat = $this->getOption('eventListDateFormat');
     $this->paginationRange = 3;
     $this->defaultStatus = $this->getOption('defaultStatus');
     $this->emailAlertsEnabled = $this->getOption('emailAlertsEnabled');
     $emailAlertsList = $this->getOption('emailAlertsList');
     $this->emailAlertsList = explode("\n", $emailAlertsList);
     $this->blockRolesFromAdmin = $this->getOption('blockRolesFromAdmin');
     $this->blockRolesList = $this->getOption('blockRolesList');
     $this->blockRolesRedirect = $this->getOption('blockRolesRedirect', get_home_url()) == '' ? get_home_url() : $this->getOption('blockRolesRedirect', get_home_url());
     $this->maybeFlushRewrite = $this->getOption('maybeFlushRewrite');
     if ($this->blockRolesFromAdmin) {
         add_action('init', array($this, 'blockRolesFromAdmin'));
     }
     $this->pluginDir = trailingslashit(basename(dirname(dirname(__FILE__))));
     $this->pluginPath = trailingslashit(dirname(dirname(__FILE__)));
     $this->pluginUrl = plugins_url('', dirname(__FILE__));
     $this->pluginSlug = 'events-community';
     $this->isMyEvents = false;
     $this->isEditPage = false;
     $this->communityRewriteSlug = $this->getOption('communityRewriteSlug', 'community');
     $this->rewriteSlugs['edit'] = sanitize_title(__('edit', 'tribe-events-community'));
     $this->rewriteSlugs['add'] = sanitize_title(__('add', 'tribe-events-community'));
     $this->rewriteSlugs['delete'] = sanitize_title(__('delete', 'tribe-events-community'));
     $this->rewriteSlugs['list'] = sanitize_title(__('list', 'tribe-events-community'));
     $this->rewriteSlugs['venue'] = sanitize_title(__('venue', 'tribe-events-community'));
     $this->rewriteSlugs['organizer'] = sanitize_title(__('organizer', 'tribe-events-community'));
     $this->rewriteSlugs['event'] = sanitize_title(__('event', 'tribe-events-community'));
     if ('' == get_option('permalink_structure')) {
         add_shortcode('tribe_community_events', array($this, 'doShortCode'));
         add_shortcode('tribe_community_events_title', array($this, 'doShortCodeTitle'));
         //allow shortcodes for dynamic titles
         add_filter('the_title', 'do_shortcode');
         add_filter('wp_title', 'do_shortcode');
         add_action('template_redirect', array($this, 'maybeRedirectMyEvents'));
     } else {
         add_action('template_redirect', array($this, 'redirectUglyUrls'));
     }
     // in 3.5 this is causing an error moved self::maybeLoadAssets(); into function init()...
     add_action('wp', array($this, 'maybeLoadAssets'));
     add_action('init', array($this, 'init'));
     add_action('admin_init', array($this, 'maybeFlushRewriteRules'));
     add_action('wp_before_admin_bar_render', array($this, 'addCommunityToolbarItems'), 20);
     // Tribe common resources
     TribeCommonLibraries::register('wp-router', '0.3', $this->pluginPath . 'vendor/wp-router/wp-router.php');
     add_action('tribe_settings_save_field_allowAnonymousSubmissions', array($this, 'flushRewriteOnAnonymous'), 10, 2);
     add_filter('query_vars', array($this, 'communityEventQueryVars'));
     add_filter('body_class', array($this, 'setBodyClasses'));
     // ensure that we don't include tabindexes in our form fields
     add_filter('tribe_events_tab_index', '__return_null');
     add_filter('tribe_tec_addons', array('TribeCommunityEvents', 'init_addon'));
     // options page hook
     add_action('tribe_settings_do_tabs', array($this, 'doSettings'), 10, 1);
     add_action('wp_router_generate_routes', array($this, 'addRoutes'));
     add_action('plugin_action_links_' . trailingslashit($this->pluginDir) . 'tribe-community-events.php', array($this, 'addLinksToPluginActions'));
     add_action('tribe_events_community_form', array($this, 'tribe_events_community_form'), 10, 3);
     add_filter('tribe_help_tab_forums_url', array($this, 'helpTabForumsLink'), 100);
     add_action('save_post', array($this, 'flushPageIdTransient'), 10, 1);
     add_filter('user_has_cap', array($this, 'filter_user_caps'), 10, 3);
     if (is_multisite()) {
         add_action('tribe_settings_get_option_value_pre_display', array($this, 'multisiteDefaultOverride'), 10, 3);
     }
 }