Tribe__Repository::add_simple_meta_schema_entry( string $key, string|array $meta_key, string|null $by = null )

Adds a simple meta entry to the repository filter schema.


Parameters

$key

(string) (Required) The filter key, the one that will be used in by and where calls.

$meta_key

(string|array) (Required) The meta key(s) to use for the meta lookup.

$by

(string|null) (Optional) The ->by() lookup to use (defaults to meta_regexp_or_like).

Default value: null


Top ↑

Source

File: src/Tribe/Repository.php

	public function add_simple_meta_schema_entry( $key, $meta_key, $by = null ) {
		$this->schema[ $key ] = array( $this, 'filter_by_simple_meta_schema' );

		$this->simple_meta_schema[ $key ] = array(
			'meta_key' => $meta_key,
			'by'       => $by,
		);
	}

Top ↑

Changelog

Changelog
Version Description
4.9.5 Introduced.