Support Online : Mon - Fri / 10am - 6pm (GMT +6)

Your Time: Our Time:

Category description is missing

Featured Lock Resolved Bug
When show category description is switched on and there is text in the category description it does not output on a blog view.
I switched to beez3 and its outputting, switch back and its not there even in the code.

Images are same page just switching between templates missing_cat_description.png description_not_showing.png

Attachments (2)

  • missing_cat_description.png
    missing_cat_description.png 760.7 KB
  • description_not_showing.png
    description_not_showing.png 395.7 KB

7 Answers

Sifat - Staff

More than a month ago #Permalink
Hi,
Thanks for your query. Please follow the following steps:
1) Goto this file location /templates/shaper_gazette/html/com_content/category/blog.php
2) Then just replace the attached file there.
3) Here is the final output http://prntscr.com/mpu2o3

-Best Regards

Attachments (1)

  • blog.zip 2.2 KB
Hi,
Thanks for your query. Please follow the following steps:
1) Goto this file location /templates/shaper_gazette/html/com_content/category/blog.php
2) Then just replace the attached file there.
3) Here is the final output http://prntscr.com/mpu2o3

-Best Regards


This now outputs
params->get('show_description') == 1):?>
Explore the latest news from TRANSNET.

This :-
params->get('show_description') == 1):?>
Should not be showing

Sifat - Staff

More than a month ago #Permalink
Please replace this attached file and let me know if that helps.

Attachments (1)

  • blog.zip 2.2 KB
Thanks, the latest kills the site
0
syntax error, unexpected end of file, expecting elseif (T_ELSEIF) or else (T_ELSE) or endif (T_ENDIF)

Do you ever test them before sending?
<?php
/**
* @package Helix Ultimate Framework
* @author JoomShaper https://www.joomshaper.com
* @copyright Copyright (c) 2010 - 2018 JoomShaper
* @license http://www.gnu.org/licenses/gpl-2.0.html GNU/GPLv2 or Later
*/


defined ('_JEXEC') or die();

JHtml::addIncludePath(JPATH_COMPONENT . '/helpers');

JHtml::_('behavior.caption');

$app = JFactory::getApplication();
$doc = JFactory::getDocument();

$this->category->text = $this->category->description;
$app->triggerEvent('onContentPrepare', array($this->category->extension . '.categories', &$this->category, &$this->params, 0));
$this->category->description = $this->category->text;


$results = $app->triggerEvent('onContentAfterTitle', array($this->category->extension . '.categories', &$this->category, &$this->params, 0));
$afterDisplayTitle = trim(implode("\n", $results));

$results = $app->triggerEvent('onContentBeforeDisplay', array($this->category->extension . '.categories', &$this->category, &$this->params, 0));
$beforeDisplayContent = trim(implode("\n", $results));

$results = $app->triggerEvent('onContentAfterDisplay', array($this->category->extension . '.categories', &$this->category, &$this->params, 0));
$afterDisplayContent = trim(implode("\n", $results));

?>

<div class="blog<?php echo $this->pageclass_sfx; ?>">
<?php if($this->params->get('show_description') == 1) : ?>
<div class="category-desc">
<?php echo $this->category->description; ?>
</div>
<?php endif; ?>
<?php if ($this->params->get('show_page_heading')) : ?>
<div class="page-header">
<h1><?php echo $this->escape($this->params->get('page_heading')); ?></h1>
</div>
<?php endif; ?>

<?php if ($this->params->get('show_category_title', 1) or $this->params->get('page_subheading')) : ?>
<h2>
<?php echo $this->escape($this->params->get('page_subheading')); ?>
<?php if ($this->params->get('show_category_title')) : ?>
<span class="subheading-category"><?php echo $this->category->title; ?></span>
<?php endif; ?>
</h2>
<?php endif; ?>
<?php echo $afterDisplayTitle; ?>

<?php if ($this->params->get('show_cat_tags', 1) && !empty($this->category->tags->itemTags)) : ?>
<?php $this->category->tagLayout = new JLayoutFile('joomla.content.tags'); ?>
<?php echo $this->category->tagLayout->render($this->category->tags->itemTags); ?>
<?php endif; ?>



<?php if (empty($this->lead_items) && empty($this->link_items) && empty($this->intro_items)) : ?>
<?php if ($this->params->get('show_no_articles', 1)) : ?>
<p><?php echo JText::_('COM_CONTENT_NO_ARTICLES'); ?></p>
<?php endif; ?>
<?php endif; ?>

<?php if (!empty($this->lead_items)) : ?>
<div class="article-list articles-leading clearfix">
<?php foreach ($this->lead_items as &$item) : ?>
<div class="article<?php echo $item->state == 0 ? ' system-unpublished' : null; ?>"
itemprop="blogPost" itemscope itemtype="https://schema.org/BlogPosting">
<?php
$this->item = & $item;
$this->item->leading = true;
echo $this->loadTemplate('item');
?>
</div>
<?php endforeach; ?>
</div>
<?php endif; ?>

<?php
$introcount = count($this->intro_items);
$counter = 0;
?>

<?php if (!empty($this->intro_items)) : ?>
<div class="article-list">
<div class="row">
<?php foreach ($this->intro_items as $key => &$item) : ?>
<div class="col-md-<?php echo round(12 / $this->columns); ?>">
<div class="article <?php echo $item->state == 0 ? ' system-unpublished' : null; ?>"
itemprop="blogPost" itemscope itemtype="https://schema.org/BlogPosting">
<?php
$this->item = & $item;
echo $this->loadTemplate('item');
?>
</div>
<?php $counter++; ?>
</div>
<?php endforeach; ?>
</div>
</div>
<?php endif; ?>

<!-- if item has 3 then module position will be set -->
<?php if ($doc->countModules('bloglist-ad')) { ?>
<div class="bloglist-add items-row row clearfix">
<div class="col-sm-12">
<?php
jimport('joomla.application.module.helper');
$modules = JModuleHelper::getModules('bloglist-ad');
$attribs['style'] = 'sp_xhtml';

foreach ($modules as $key => $module) {
echo JModuleHelper::renderModule($module, $attribs);
}
?>
</div> <!-- /.col-sm- -->
</div> <!-- /.items-row -->
<?php } ?> <!-- // END:: key condition -->

<?php if (!empty($this->link_items)) : ?>
<div class="articles-more">
<?php echo $this->loadTemplate('links'); ?>
</div>
<?php endif; ?>

<?php if ($this->maxLevel != 0 && !empty($this->children[$this->category->id])) : ?>
<div class="cat-children">
<?php if ($this->params->get('show_category_heading_title_text', 1) == 1) : ?>
<h3> <?php echo JText::_('JGLOBAL_SUBCATEGORIES'); ?> </h3>
<?php endif; ?>
<?php echo $this->loadTemplate('children'); ?> </div>
<?php endif; ?>

<?php if (($this->params->def('show_pagination', 1) == 1 || ($this->params->get('show_pagination') == 2)) && ($this->pagination->pagesTotal > 1)) : ?>
<nav class="d-flex pagination-wrapper">
<?php if ($this->params->def('show_pagination_results', 1)) : ?>
<div class="mr-auto">
<?php echo $this->pagination->getPagesLinks(); ?>
</div>
<?php endif; ?>
</nav>
<?php endif; ?>

</div>
Above is the code without the error, correct php tags etc, can you please add the category description to your templates

Sifat - Staff

More than a month ago #Permalink
Thanks for your reply. Actually that template doesn't have those options to show in design. That's why those were not used. I'll talk to the developers about that.

-Best Regards


There are no replies made for this post yet.
Be one of the first to reply to this post!

Leaderboard (30 days)

Paul Frankowski

Paul Frankowski

Total Accepted Answers: 116
Toufiq

Toufiq

Total Accepted Answers: 82
Mehtaz Afsana Borsha

Mehtaz Afsana Borsha

Total Accepted Answers: 71
Ofi Khan

Ofi Khan

Total Accepted Answers: 43
Rashida Rahman

Rashida Rahman

Total Accepted Answers: 37

121

Templates

315320

Community Users

Newsletter

Don’t miss any updates of our new templates and extensions and all the astonishing offers we bring for you.
We never spam

Joomla! ® name is used under a limited license from Open Source Matters in the United States and other countries. JoomShaper.com is not affiliated with or endorsed by Open Source Matters or the Joomla! Project.

Connect Us