[ Index ]

PHP Cross Reference of Joomla 4.2.2 documentation

title

Body

[close]

/layouts/joomla/content/info_block/ -> category.php (source)

   1  <?php
   2  
   3  /**
   4   * @package     Joomla.Site
   5   * @subpackage  Layout
   6   *
   7   * @copyright   (C) 2013 Open Source Matters, Inc. <https://www.joomla.org>
   8   * @license     GNU General Public License version 2 or later; see LICENSE.txt
   9   */
  10  
  11  defined('_JEXEC') or die;
  12  
  13  use Joomla\CMS\Language\Text;
  14  use Joomla\CMS\Layout\LayoutHelper;
  15  use Joomla\CMS\Router\Route;
  16  use Joomla\Component\Content\Site\Helper\RouteHelper;
  17  
  18  ?>
  19  <dd class="category-name">
  20      <?php echo LayoutHelper::render('joomla.icon.iconclass', ['icon' => 'icon-folder-open icon-fw']); ?>
  21      <?php $title = $this->escape($displayData['item']->category_title); ?>
  22      <?php if ($displayData['params']->get('link_category') && !empty($displayData['item']->catid)) : ?>
  23          <?php $url = '<a href="' . Route::_(
  24              RouteHelper::getCategoryRoute($displayData['item']->catid, $displayData['item']->category_language)
  25          )
  26              . '" itemprop="genre">' . $title . '</a>'; ?>
  27          <?php echo Text::sprintf('COM_CONTENT_CATEGORY', $url); ?>
  28      <?php else : ?>
  29          <?php echo Text::sprintf('COM_CONTENT_CATEGORY', '<span itemprop="genre">' . $title . '</span>'); ?>
  30      <?php endif; ?>
  31  </dd>


Generated: Wed Sep 7 05:41:13 2022 Chilli.vc Blog - For Webmaster,Blog-Writer,System Admin and Domainer