PHP 클래스 Yosymfony\Spress\Core\ContentManager\Generator\Taxonomy\TaxonomyGenerator

This generator uses PaginationGenerator for generating multiples pages for each term. This means that PaginationGenerator's attributes are available with TaxonomyGenerator. Example of URLs generated: categories/news categories/news/page2 ... This generator adds an attribute "terms_url" to each items processed with the permalinks of the terms. The patter follows is $attributes['terms_url'][$taxonomy_attribute][$term]. e.g: for "categories" as taxonomy_attribute and "news" as term $attributes['terms_url']['categories']['news'] Notice that terms are normalized to lower case and then they are sluged. That means certain words from cyrillic languages for example, could point to the same normalized term. e.g: "bash", "баш" are pointing to "bash" term. How to configure? (Front matter block of the template page): --- layout: 'default' generator: 'taxonomy' max_page: 5 taxonomy_attribute: 'categories' permalink: '/:name' pagination_permalink: '/page:num' ---
저자: Victor Puertas ([email protected])
상속: implements Yosymfony\Spress\Core\ContentManager\Generator\GeneratorInterface
파일 보기 프로젝트 열기: spress/spress

공개 메소드들

메소드 설명
generateItems ( Yosymfony\Spress\Core\DataSource\ItemInterface $templateItem, array $collections )

보호된 메소드들

메소드 설명
getAttributesResolver ( Yosymfony\Spress\Core\DataSource\ItemInterface $templateItem )
getTermPermalink ( $TermRelativePath )
getTermRelativePath ( $basePath, $permalinkTemplate, $term )
normalizeTerm ( $term )
setTermsPermalink ( array $items, $taxonomyAttribute, array $terms, $termRelativePath )

메소드 상세

generateItems() 공개 메소드

public generateItems ( Yosymfony\Spress\Core\DataSource\ItemInterface $templateItem, array $collections )
$templateItem Yosymfony\Spress\Core\DataSource\ItemInterface
$collections array

getAttributesResolver() 보호된 메소드

protected getAttributesResolver ( Yosymfony\Spress\Core\DataSource\ItemInterface $templateItem )
$templateItem Yosymfony\Spress\Core\DataSource\ItemInterface

getTermRelativePath() 보호된 메소드

protected getTermRelativePath ( $basePath, $permalinkTemplate, $term )

normalizeTerm() 보호된 메소드

protected normalizeTerm ( $term )