Joomla CMS  4.2.2
Documentation des API du CMS Joomla en version 4.2.2
Référence du fichier category_default.php

Espaces de nommage

 Joomla\Site
 

Variables

 $params = $displayData->params
 
 $category = $displayData->get('category')
 
 $extension = $category->extension
 
 $canEdit = $params->get('access-edit')
 
 $className = substr($extension, 4)
 
 $htag = $params->get('show_page_heading') ? 'h2' : 'h1'
 
 $app = Factory::getApplication()
 
$category text = $category->description
 
$category description = $category->text
 
 $results = $app->triggerEvent('onContentAfterTitle', array($extension . '.categories', &$category, &$params, 0))
 
 $afterDisplayTitle = trim(implode("\n", $results))
 
 $beforeDisplayContent = trim(implode("\n", $results))
 
 $afterDisplayContent = trim(implode("\n", $results))
 
if(substr($className, -1)==='s') $tagsData = $category->tags->itemTags
 
 endif
 
 if ( $params->get( 'show_category_title', 1))
 

Documentation des variables

◆ $afterDisplayContent

$afterDisplayContent = trim(implode("\n", $results))

◆ $afterDisplayTitle

$afterDisplayTitle = trim(implode("\n", $results))

◆ $app

$app = Factory::getApplication()

◆ $beforeDisplayContent

$beforeDisplayContent = trim(implode("\n", $results))

◆ $canEdit

$canEdit = $params->get('access-edit')

◆ $category

$category = $displayData->get('category')

◆ $className

$className = substr($extension, 4)

◆ $extension

◆ $htag

$htag = $params->get('show_page_heading') ? 'h2' : 'h1'

◆ $params

$params = $displayData->params

Note that this layout opens a div with the page class suffix. If you do not use the category children layout you need to close this div either by overriding this file or in your main layout.

◆ $results

$results = $app->triggerEvent('onContentAfterTitle', array($extension . '.categories', &$category, &$params, 0))

◆ $tagsData

if (substr( $className, -1)==='s') $tagsData = $category->tags->itemTags

This will work for the core components but not necessarily for other components that may have different pluralisation rules.

◆ description

$category description = $category->text

◆ endif

endif

◆ if

if($params->get('show_category_title', 1))

◆ text