Bolt\TemplateChooser::taxonomy PHP Метод

taxonomy() публичный Метод

Select a template for taxonomy.
public taxonomy ( string $taxonomyslug ) : string
$taxonomyslug string
Результат string
    public function taxonomy($taxonomyslug)
    {
        // First candidate: Global config.yml
        $template = $this->app['config']->get('general/listing_template');
        // Second candidate: Theme-specific config.yml file.
        if ($this->app['config']->get('theme/listing_template')) {
            $template = $this->app['config']->get('theme/listing_template');
        }
        // Third candidate: defined specifically in the taxonomy
        if ($this->app['config']->get('taxonomy/' . $taxonomyslug . '/listing_template')) {
            $template = $this->app['config']->get('taxonomy/' . $taxonomyslug . '/listing_template');
        }
        return $template;
    }