the method of random ordering modification of Zencart new products The first step: First, the new product can define its own time period: Store Settings-maximum-the definition of a new product
the method of random ordering modification of Zencart new products The second step:
Modify the first page on the new product:
/includes/modules/new_products.php
Add corresponding order by XXX in $new_products_query
Example: SELECT DISTINCT p.products_id, p.products_image,p.products_tax_class_id, Pd.products_name, p.products_date_added, P.products_price, P.products_type, p.master_categories_id fromzen_products p, zen_products_description PD where p.products_id =pd.products_id and pd.language_id = ' 1 ' and p.products_status = 1order by pd.products_name
the method of random ordering modification of Zencart new products step three:
To modify a new item in a border:
/includes/modules/sideboxes/whats_new.php
Will
$random _whats_new_sidebox_product =zen_random_select ($random _whats_new_sidebox_product_query);
To
$random _whats_new_sidebox_product = $db->execute ($random _whats_new_sidebox_product_query);
the method of random ordering modification of Zencart new products step Fourth:
Then/includes/modules/new_products.php the file in the:
$db->executerandommulti
To
$db->execute
Movenextrandom ()
To
MoveNext ()