Featured Products in 2 or More Rows
Submitted by srl2112 on Sun, 2006-05-14 20:32.Price Tapestry
Is there a modificaton to set the featured items into 2 or more rows?
Thnaks - Steve
Support forum loginActive forum topics©2006-2008 IAAI Software |
Featured Products in 2 or More RowsSubmitted by srl2112 on Sun, 2006-05-14 20:32.Price Tapestry
Is there a modificaton to set the featured items into 2 or more rows? Thnaks - Steve |
Hi Steve,
The easiest way is to increment a counter, and output the HTML to start a new table row whenever it reaches the number of products you want in each row.
In html/featured.php, find the following code:
</td><?php endforeach; ?>
That's where each product cell is closed. You need to insert the code to start a new row between these 2 lines, as follows, so the whole section will look like this:
</td><?php
if ($count++ == 3)
{
print "</tr><tr>";
$count = 0;
}
?>
<?php endforeach; ?>
Simply change the number 3 in the above code if you want more or less products per row...
Cheers,
David.