Hi there!
Need help with removing category image from category page in OC 3.0.2.0.
I'm pretty sure that I need to modify /catalog/view/theme/default/template/product/category.twig file, but I'm not sure if, or what to modify...
Any help please?
Thank you
Need help with removing category image from category page in OC 3.0.2.0.
I'm pretty sure that I need to modify /catalog/view/theme/default/template/product/category.twig file, but I'm not sure if, or what to modify...
Any help please?
Thank you
As long as you don't set the category image, wouldn't it not show up?
Removing images while wanting to make them invisible may not provide the solution that you need. See this post for an alternate route for your store: viewtopic.php?f=184&t=206182#p731086
Dedication and passion goes to those who are able to push and merge a project.
Regards,
Straightlight
Programmer / Opencart Tester
Thanks for reply
Unfortunately, in the link that you provide, I don't see solution, it seems that is not even related to what I'm searching for (maybe I didn't understand it well).
As I recall, for 2.3.0.2, .tpl file was modified with some code (I did it some time ago with help of this forum), and thought that similar solution can be applied with .twig file in 3.x version.
So, can it?
P.S. I must have image since menus of my theme (Journal) are showing those pictures. I just don't want them on the category page, since I'm using custom code.
Thanks
Unfortunately, in the link that you provide, I don't see solution, it seems that is not even related to what I'm searching for (maybe I didn't understand it well).
As I recall, for 2.3.0.2, .tpl file was modified with some code (I did it some time ago with help of this forum), and thought that similar solution can be applied with .twig file in 3.x version.
So, can it?
P.S. I must have image since menus of my theme (Journal) are showing those pictures. I just don't want them on the category page, since I'm using custom code.
Thanks
Source unprovided.As I recall, for 2.3.0.2, .tpl file was modified with some code (I did it some time ago with help of this forum), and thought that similar solution can be applied with .twig file in 3.x version.
Dedication and passion goes to those who are able to push and merge a project.
Regards,
Straightlight
Programmer / Opencart Tester
So you want to show or remove??
]If you want to remove..then edit category and remove image from category..
]If you want to remove..then edit category and remove image from category..
Upgrade Service | OC 2.3.0.2 PHP 8 | My Custom OC 3.0.3.8 | Buy me a beer
Thanks for reply
I want category image in admin page, but i don't want it in the front end. There are 2 pictures in attachment that I think are showing what I need
Similar topics were
viewtopic.php?t=27041
viewtopic.php?t=38206
but those are for earlier versions of OC, I need it for 3.0.2.0. And I think that they involving code change in /catalog/view/theme/default/template/product/category.tpl
My guess was that it should be changed in /catalog/view/theme/default/template/product/category.twig this time (since it's OC 3) but so far - no luck
Thank you all for efforts
I want category image in admin page, but i don't want it in the front end. There are 2 pictures in attachment that I think are showing what I need
Similar topics were
viewtopic.php?t=27041
viewtopic.php?t=38206
but those are for earlier versions of OC, I need it for 3.0.2.0. And I think that they involving code change in /catalog/view/theme/default/template/product/category.tpl
My guess was that it should be changed in /catalog/view/theme/default/template/product/category.twig this time (since it's OC 3) but so far - no luck
Thank you all for efforts
Attachments
picture_2.jpg (76.59 KiB) Viewed 2416 times
picture_1.jpg (54.33 KiB) Viewed 2416 times
You can open the catalog/view/theme/default/template/product/category.twig file and remove
Or better still make a vqmod to do this
Code: Select all
{% if thumb or description %}
<div class="row"> {% if thumb %}
<div class="col-sm-2"><img src="{{ thumb }}" alt="{{ heading_title }}" title="{{ heading_title }}" class="img-thumbnail" /></div>
{% endif %}
{% if description %}
<div class="col-sm-10">{{ description }}</div>
{% endif %}</div>
<hr>
{% endif %}
This will also remove the category description from the category page, right? That would be unfavorable because a good category description helps you rank in search engines. To only remove the image, should I then only remove the part below?cyclops12 wrote: ↑Tue Aug 07, 2018 1:40 amYou can open the catalog/view/theme/default/template/product/category.twig file and removeOr better still make a vqmod to do thisCode: Select all
{% if thumb or description %} <div class="row"> {% if thumb %} <div class="col-sm-2"><img src="{{ thumb }}" alt="{{ heading_title }}" title="{{ heading_title }}" class="img-thumbnail" /></div> {% endif %} {% if description %} <div class="col-sm-10">{{ description }}</div> {% endif %}</div> <hr> {% endif %}
Code: Select all
{% if thumb %}
<div class="col-sm-2"><img src="{{ thumb }}" alt="{{ heading_title }}" title="{{ heading_title }}" class="img-thumbnail" /></div>
{% endif %}
Last edited by straightlight on Wed Apr 08, 2020 8:04 pm, edited 1 time in total.
Reason: Added code tags.
Reason: Added code tags.
Who is online
Users browsing this forum: Bing [Bot] and 11 guests