Tribe__Events__Editor__Template__Overwrite::silence( string $file )

Silence the actual templating and lets use an action to prevent Old Stuff to have any sort of interactions with what we are constructing here.


Parameters

$file

(string) (Required) Which file would be loaded


Top ↑

Return

(string)


Top ↑

Source

File: src/Tribe/Editor/Template/Overwrite.php

	public function silence( $file ) {
		$post_id = get_the_ID();

		// Prevent overwrite for posts that doens't have Blocks
		if ( ! has_blocks( $post_id ) ) {
			return $file;
		}

		return $this->get_path( 'silence' );
	}

Top ↑

Changelog

Changelog
Version Description
4.7 Introduced.