Tribe__Events__Repositories__Event::filter_by_featured( bool $featured = true )

Filters events to include only those that match the provided featured state.


Parameters

$featured

(bool) (Optional) Whether the events should be featured or not.

Default value: true


Top ↑

Source

File: src/Tribe/Repositories/Event.php

	public function filter_by_featured( $featured = true ) {
		$this->by( (bool) $featured ? 'meta_exists' : 'meta_not_exists', Tribe__Events__Featured_Events::FEATURED_EVENT_KEY, '#' );
	}

Top ↑

Changelog

Changelog
Version Description
4.9 Introduced.