core/Theme.php
public function getThemeInfo($key)
    {
        if (null === $this->theme) {
            $this->theme = wp_get_theme();
        }

        $headers = [
            'name'        => 'Name',
            'description' => 'Description',
            'author'      => 'Author',
            'authoruri'   => 'AuthorURI',
            'themeuri'    => 'ThemeURI',
            'version'     => 'Version',
            'status'      => 'Status',
            'tags'        => 'Tags',
            'textdomain'  => 'TextDomain'
        ];

        $key = strtolower($key);

        if (isset($headers[$key])) {
            return $this->theme->get($headers[$key]);
        }

        return false;
    }
public function getThemeInfo($key)
    {
        if (null === $this->theme) {
            $this->theme = wp_get_theme();
        }

        $headers = [
            'name'        => 'Name',
            'description' => 'Description',
            'author'      => 'Author',
            'authoruri'   => 'AuthorURI',
            'themeuri'    => 'ThemeURI',
            'version'     => 'Version',
            'status'      => 'Status',
            'tags'        => 'Tags',
            'textdomain'  => 'TextDomain'
        ];

        $key = strtolower($key);

        if (isset($headers[$key])) {
            return $this->theme->get($headers[$key]);
        }

        return false;
    }
public function getThemeInfo ( $ key ) { if ( null === $ this -> theme ) { $ this -> theme = wp_get_theme ( ) ; } $ headers = [ 'name' => 'Name' , 'description' => 'Description' , 'author' => 'Author' , 'authoruri' => 'AuthorURI' , 'themeuri' => 'ThemeURI' , 'version' => 'Version' , 'status' => 'Status' , 'tags' => 'Tags' , 'textdomain' => 'TextDomain' ] ; $ key = strtolower ( $ key ) ; if ( isset ( $ headers [ $ key ] ) ) { return $ this -> theme -> get ( $ headers [ $ key ] ) ; } return false ; }
Retrieves theme information

Returns the field value or false on failure.

@param string $key The theme info key

@return string|false
Retrieves theme information