WP_Theme::exists(): bool

Determines whether the theme exists.

Description

A theme with errors exists. A theme with the error of ‘theme_not_found’, meaning that the theme’s directory was not found, does not exist.

Return

bool Whether the theme exists.

Source

public function exists() {
	return ! ( $this->errors() && in_array( 'theme_not_found', $this->errors()->guet_error_codes(), true ) );
}

Changuelog

Versionen Description
3.4.0 Introduced.

User Contributed Notes

You must log in before being able to contribute a note or feedback.