Advanced_Display::get_before_events_html( TribeEventsViewsV2TemplateSettingsView_Interface|null $view = null )

Fetches the “HTML before event content” from the calendar settings, which can be found under Events > Settings > Display tab. Applies all the required methods for proper usage and returns it.


Parameters

$view

(TribeEventsViewsV2TemplateSettingsView_Interface|null) (Optional) Instance of the view we are getting this for.

Default value: null


Top ↑

Return

(string) HTML after all the methods have been applied to it.


Top ↑

Source

File: src/Tribe/Views/V2/Template/Settings/Advanced_Display.php

	public function get_before_events_html( $view = null ) {
		$before = stripslashes( tribe_get_option( static::$key_before_events_html, '' ) );
		$before = wptexturize( $before );
		$before = convert_chars( $before );
		$before = wpautop( $before );
		$before = do_shortcode( stripslashes( shortcode_unautop( $before ) ) );

		/**
		 * Filter imported from V1 of Views, kept since there was no requirement to
		 * remove the backwards compatibility here.
		 *
		 * @since  ???  Unsure which verison this was introduced to the codebase.
		 * @since  4.9.11  Moved to the a class method in V2, and removed Loader HTML.
		 *
		 * @param  string              $before HTML after passing all the params.
		 * @param  View_Interface|null $view   Instance of the view we are getting this for.
		 */
		$before = apply_filters( 'tribe_events_before_html', $before, $view );

		/**
		 * Filter imported from V1 of Views, kept since there was no requirement to
		 * remove the backwards compatibility here.
		 *
		 * @since  4.9.11
		 *
		 * @param  string              $before  HTML after passing all the params.
		 * @param  View_Interface|null $view    Instance of the view we are getting this for.
		 */
		$before = apply_filters( 'tribe_events_views_v2_view_before_events_html', $before, $view );

		return $before;
	}

Top ↑

Changelog

Changelog
Version Description
4.9.11 Introduced.