Okay I find 3 instances of
$cartplog['popular_products'] in the
cartplog.php file. But I don't understand when you said "and in the prededing query add a
limit."
PHP Code:
$db->free_result($cartplog_product_info);
$cartplog_product_infos = $db->query_read("SELECT productid, catid, thumb, title, price
FROM " . TABLE_PREFIX . "cartplog_products
WHERE sales = " . intval($cartplog_max_salescnt) . "
");
$cartplog['popular_products'] = '';
while ($cartplog_product_info = $db->fetch_array($cartplog_product_infos))
{
$cartplog['product_productid'] = intval($cartplog_product_info['productid']);
$cartplog['product_catid'] = intval($cartplog_product_info['catid']);
$cartplog['product_thumb'] = strval($cartplog_product_info['thumb']);
$cartplog['product_title'] = htmlspecialchars_uni($cartplog_product_info['title']);
$cartplog['product_price'] = round(floatval($cartplog_product_info['price']), 2);
eval('$cartplog[\'popular_products\'] .= "' . fetch_template('cartplog_product_item') . '";');
$cartplog['popular_products'] .= '</tr><tr>';
}
$db->free_result($cartplog_product_infos);
$cartplog['popular_products'] = eregi_replace(preg_quote('</tr><tr>') . '$', '',