Written by me@grafxflow
27 Sep, 2012
0
3,082
The problem I had was to change the number of products on each row on the search results page from 4 to 3.
I was also using version 1.4.9.3 of OpenCart and I couldn't find a way via the admin, but after searching I managed to solve the problem by changing some code instead.
The page can be found in either
catalog/view/theme/default/template/product/search.tpl
or
catalog/view/theme/[your_theme_name]/template/product/search.tpl
Then find the following segment of code.
<table class="list">
<?php for ($i = 0; $i < sizeof($products); $i = $i + 4) { ? >
<tr>
<?php for ($j = $i; $j < ($i + 4); $j++) { ? >
and change it to the new number in both places
<table class="list">
<?php for ($i = 0; $i < sizeof($products); $i = $i + 3) { ? >
<tr>
<?php for ($j = $i; $j < ($i + 3); $j++) { ? >
01 Jan, 2013
24 Nov, 2013
07 Nov, 2012
I am a Full-stack Developer who also started delving into the world of UX/UI Design a few years back. I blog and tweet to hopefully share a little bit of knowledge that can help others around the web. Thanks for stopping by!
Follow11 Jul, 2023
21 Jun, 2023
Views: 166,097
Views: 40,208
Views: 36,920
Views: 33,515