Page 1 of 1
Show product Code in Category Items / list / grid
Posted: Tue Oct 22, 2019 8:26 pm
by BGamer
Hello, how do I show the product code in the category graph? ( list / grid ) I have seen old reviews but do not fit my version 3.0.2.0
Re: Show product Code in Category Items / list / grid
Posted: Tue Oct 22, 2019 9:24 pm
by DigitCart
Hi
in this file:
catalog\controller\product\category.php
Find:
Add after it:
in this file:
catalog\view\theme\default\template\product\category.twig
Find:
Code: Select all
<h4><a href="{{ product.href }}">{{ product.name }}</a></h4>
Add after it:
Code: Select all
{% if product.model is defined %}Product Code: {{ product.model }}{% endif %}
This is for default theme.
you may need to refresh the modification and clear the caches.
Re: Show product Code in Category Items / list / grid
Posted: Wed Oct 23, 2019 3:09 pm
by BGamer
Thank you, this method works in 3.0.2.0
Re: Show product Code in Category Items / list / grid
Posted: Wed Oct 23, 2019 4:39 pm
by DigitCart
You are welcome.
Re: Show product Code in Category Items / list / grid
Posted: Fri Sep 01, 2023 12:57 am
by Ehsan Samara
Hello... can you please help me how to do it in 4.0.2.2 version..
Thanks