The category pages shows unwanted categories on top, how to remove them.
See attachement to visualise the problem. Or click this link to my webshop. https://goo.gl/rv9aco
Thanks guys!
Hi,
Those are the thumbs of sub-categories.
In default theme you can remove sub-categories list in category page by editing this file:
and removing this part:
Look for similar code in your custom theme.
Those are the thumbs of sub-categories.
In default theme you can remove sub-categories list in category page by editing this file:
Code: Select all
catalog\view\theme\default\template\product\category.tpl
Code: Select all
<?php if ($categories) { ?>
<h3><?php echo $text_refine; ?></h3>
<?php if (count($categories) <= 5) { ?>
<div class="row">
<div class="col-sm-3">
<ul>
<?php foreach ($categories as $category) { ?>
<li><a href="<?php echo $category['href']; ?>"><?php echo $category['name']; ?></a></li>
<?php } ?>
</ul>
</div>
</div>
<?php } else { ?>
<div class="row">
<?php foreach (array_chunk($categories, ceil(count($categories) / 4)) as $categories) { ?>
<div class="col-sm-3">
<ul>
<?php foreach ($categories as $category) { ?>
<li><a href="<?php echo $category['href']; ?>"><?php echo $category['name']; ?></a></li>
<?php } ?>
</ul>
</div>
<?php } ?>
</div>
<?php } ?>
<?php } ?>
Hmz coding. Not my kind of thing to be honoust. Isn't there a more easy way?DigitCart wrote: ↑Fri Dec 15, 2017 7:38 pmHi,
Those are the thumbs of sub-categories.
In default theme you can remove sub-categories list in category page by editing this file:and removing this part:Code: Select all
catalog\view\theme\default\template\product\category.tpl
Look for similar code in your custom theme.Code: Select all
<?php if ($categories) { ?> <h3><?php echo $text_refine; ?></h3> <?php if (count($categories) <= 5) { ?> <div class="row"> <div class="col-sm-3"> <ul> <?php foreach ($categories as $category) { ?> <li><a href="<?php echo $category['href']; ?>"><?php echo $category['name']; ?></a></li> <?php } ?> </ul> </div> </div> <?php } else { ?> <div class="row"> <?php foreach (array_chunk($categories, ceil(count($categories) / 4)) as $categories) { ?> <div class="col-sm-3"> <ul> <?php foreach ($categories as $category) { ?> <li><a href="<?php echo $category['href']; ?>"><?php echo $category['name']; ?></a></li> <?php } ?> </ul> </div> <?php } ?> </div> <?php } ?> <?php } ?>
PS: I use Journal 2, it hasn't the same code as above
Who is online
Users browsing this forum: No registered users and 19 guests