get_allowed_themes()

最后更新于:2021-11-26 04:12:57

get_allowed_themes()

Get the allowed themes for the current site.

响应

(GC_Theme[]) Array of GC_Theme objects keyed by their name.

源文件

文件: gc-admin/includes/deprecated.php

function get_allowed_themes() {
	_deprecated_function( __FUNCTION__, '3.4.0', "gc_get_themes( array( 'allowed' => true ) )" );

	$themes = gc_get_themes( array( 'allowed' => true ) );

	$gc_themes = array();
	foreach ( $themes as $theme ) {
		$gc_themes[ $theme->get('Name') ] = $theme;
	}

	return $gc_themes;
}