View::get_view_slug( string $view )

Returns the slug currently associated to a View class, if any.


Parameters

$view

(string) (Required) The view fully qualified class name.


Top ↑

Return

(int|string|false) The slug currently associated to a View class if it is found, false otherwise.


Top ↑

Source

File: src/Tribe/Views/V2/View.php

	public static function get_view_slug( $view ) {
		$views = self::get_registered_views();

		return array_search( $view, $views, true );
	}

Top ↑

Changelog

Changelog
Version Description
4.9.2 Introduced.