Post by wenza8 » Mon Apr 11, 2016 12:00 pm

I want to show latest product in home.tpl opencart 1.5.6.4 manually without using latest module. How to do that? Thanks

Newbie

Posts

Joined
Mon May 04, 2015 9:48 pm

Post by grgr » Mon Apr 11, 2016 4:06 pm

I think that's a little involved for a forum answer.

the long and short of it is that you will need to copy the latest.php controller code into the home.php controller file.

You need to remove the remove the line relating to the template and render bit from the bottom of latest code and also define 'limit' => $setting['limit'] (i.e. 'limit' => 5). Obviously you don't want the first 2 or the last 2 lines either.

Then you need to add suitable html to the /common/home.tpl template file, I suggest that you use the /module/latest.tpl as a guide.

-
Image Image Image
VIEW ALL EXTENSIONS * EXTENSION SUPPORT * WEBSITE * CUSTOM REQUESTS


User avatar
Active Member

Posts

Joined
Mon Mar 28, 2011 4:08 pm
Location - UK
Who is online

Users browsing this forum: No registered users and 4 guests