Post by faria » Tue Oct 10, 2017 9:48 pm

Hi,
I'm using Opencart Version 3.0.2.0, and need to display image/thumb on sub category page.

Tray to change file ...\catalog\controller\product\category.php

after

Code: Select all

'name'=> $result['name'],
add

Code: Select all

'image'=> $this->model_tool_image->resize($result['image'], 80,80),
and change file .... \catalog\view\theme\default\template\product\category.twig

after

Code: Select all

{% for category in categories %}
<li><a href="{{ category.href }}">{{ category.name }}</a></li>
{% endfor %}
add

Code: Select all

 {% for category in categories %}
{% if thumb %}
<div class="col-sm-3"><img src="{{ thumb }}" alt="{{ heading_title }}" title="{{ heading_title }}" class="img-thumbnail" /></div>
 {% endif %}
<li><a href="{{ category.href }}">{{ category.name }}</a></li>
{% endfor %}
but nothing hapend ! ???

Anyone?

Newbie

Posts

Joined
Mon Oct 09, 2017 11:23 pm

Post by yodapt » Tue Oct 10, 2017 10:59 pm

Code: Select all

'thumb'=> $this->model_tool_image->resize($result['image'], 80,80),

Opencart Developer - My Extension Showcase
Contact me at aeon.yoda@gmail.com


User avatar
Active Member

Posts

Joined
Fri Jun 17, 2011 6:39 pm


Post by faria » Wed Oct 11, 2017 12:04 am

yodapt wrote:
Tue Oct 10, 2017 10:59 pm

Code: Select all

'thumb'=> $this->model_tool_image->resize($result['image'], 80,80),
dont work :(

Newbie

Posts

Joined
Mon Oct 09, 2017 11:23 pm

Post by yodapt » Wed Oct 11, 2017 12:14 am

Did you clear cache?

Opencart Developer - My Extension Showcase
Contact me at aeon.yoda@gmail.com


User avatar
Active Member

Posts

Joined
Fri Jun 17, 2011 6:39 pm


Post by ralphmitchell » Tue Dec 19, 2017 3:38 am

Yes, I think that the main problem is in the cache too

I just made my first tattoo. This is couple of pearl dolphins. I was waiting for that for a long time


Newbie

Posts

Joined
Mon Dec 18, 2017 8:47 pm

Post by gitbro » Sat Jan 20, 2018 11:44 pm

faria, did you ever get this to work.

New member

Posts

Joined
Sat Oct 31, 2015 6:58 am

User avatar
Guru Member
Online

Posts

Joined
Mon Aug 22, 2011 11:01 pm
Location - London Gatwick, United Kingdom

Post by phpscript7 » Thu Apr 28, 2022 2:46 pm

paulfeakins wrote:
Mon Apr 25, 2022 9:39 pm
Try this one: https://www.opencart.com/index.php?rout ... n_id=43446
Now that the issue has been resolved, please add: [SOLVED] at the beginning of the subject line on your first post.

New member

Posts

Joined
Wed Jan 04, 2017 3:55 pm

Post by kestas » Fri Apr 29, 2022 3:06 am

faria wrote:
Tue Oct 10, 2017 9:48 pm
Hi,
I'm using Opencart Version 3.0.2.0, and need to display image/thumb on sub category page.


but nothing hapend ! ???

Anyone?
If you need for front end try this one: https://www.opencart.com/index.php?rout ... n_id=43662

Custom OpenCart modules and solutions. You can write PM with additional questions... Extensions you can find here


Active Member

Posts

Joined
Tue Oct 12, 2010 2:23 am
Who is online

Users browsing this forum: edkny, nonnedelectari and 402 guests