W3cubDocs

/WordPress

WP_Theme::offsetExists( mixed $offset )

Method to implement ArrayAccess for keys formerly returned by get_themes()

Parameters

$offset

(mixed) (Required)

Return

(bool)

Source

File: wp-includes/class-wp-theme.php

public function offsetExists( $offset ) {
		static $keys = array(
			'Name',
			'Version',
			'Status',
			'Title',
			'Author',
			'Author Name',
			'Author URI',
			'Description',
			'Template',
			'Stylesheet',
			'Template Files',
			'Stylesheet Files',
			'Template Dir',
			'Stylesheet Dir',
			'Screenshot',
			'Tags',
			'Theme Root',
			'Theme Root URI',
			'Parent Theme',
		);

		return in_array( $offset, $keys, true );
	}

Changelog

Version Description
3.4.0 Introduced.

© 2003–2019 WordPress Foundation
Licensed under the GNU GPLv2+ License.
https://developer.wordpress.org/reference/classes/wp_theme/offsetexists