News:

You may pay someone to create your store, or you visit our seminar and become a professional yourself with the silver certification

Main Menu

[FIXED] Bug in Recently Viewed Products

Started by doorknob, April 22, 2009, 02:16:59 AM

Previous topic - Next topic

doorknob

If a product or category is unpublished, products may still be included in the list of recently viewed items. I fixed this by changing ps_product.php lines 2708 & 2709 from:
$q .= "AND c.category_id=cx.category_id LIMIT 0,1";
$db->query( $q );

to
$q .= "AND c.category_id=cx.category_id ";
$q .= "AND p.product_publish='Y' ";
$q .= "AND c.category_publish='Y' ";
$q .= "LIMIT 0,1";
$db->query( $q );
if( !$db->next_record() ) {
continue;
}


Regards
Phil
J1.5.10 vm 1.1.3 (build 1723)