ZenCart – New Products Sort Order Descending Latest

To set the descending order in zencart for new products showing latest products on the top, in descending order, here is the code you have to change, to set your latest products to display on top as New Products.

New Products Sort Order Descending

To show latest products in descending order in zencart, please open up the new_products.php file, existing in the following path:


or if you are using a zencart theme, then it should be appearing in your theme path as:


After opening the new_products.php file, add the following line of code:

$new_products_query .= ” ORDER BY products_date_added DESC

right before the following line:

if ($new_products_query != ”) $new_products = $db->ExecuteRandomMulti($new_products_query, MAX_DISPLAY_NEW_PRODUCTS);

Once you’re done, save the file and check out your new products, displaying in the homepage. Now you will be able to display your latest products in descending sort order in your homepage.

If you have any comments, or you have any other solution, please post your comment and let us know.

Leave a Reply

Your email address will not be published. Required fields are marked *

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>