Jump to content
  • Checkout
  • Login
  • Get in touch


The e-commerce.

New Products to show Weekly Products??


Recommended Posts

I'm setting up a Comic Shop related virtual store front, and I'd like to change the New Products section on the main page to show ALL products entered for a given week instead of a limited number for the month.


Comics ship on a weekly basis, so I need the visitor to see whats available for that week. I'll be adding in products that will be shipping in the future, but I don't want them to be viewed in the new products section until their week.


Can I follow the directions in the user guide and just change the month(p.products..... to week(p.products... ??

Link to comment
Share on other sites

Okay, no one's replied to this and I'm still having problems getting this to work correctly.


On the main page /catalog/default.php I want a series of products that are set for sale in a given week, that are enetered into the catalog to display in the middle of the page where it says "New Products for February". Comic Books ship on a weekly basis, so it's important that I have that weeks products out in front of my customers obviously. Below that second I'd like to continue to display upcoming Products.


Right now only nine of the comics I've entered for this week display... I need to change that so that everything I've entered for this week, display. Whatever I have entered for a given week (and it will vary from week to week), needs to display.


In /catalog/products_new.php I changed $products_new_query_raw so that it looks like this:



$products_new_query_raw = "select p.products_id, pd.products_name, p.products_image, p.products_price, p.products_tax_class_id, p.products_date_available, p.products_date_added, IF(s.status, s.specials_new_products_price, NULL) as specials_new_products_price, p.products_date_added, m.manufacturers_name from " . TABLE_PRODUCTS . " p left join " . TABLE_MANUFACTURERS . " m on p.manufacturers_id = m.manufacturers_id left join " . TABLE_PRODUCTS_DESCRIPTION . " pd on p.products_id = pd.products_id and pd.language_id = '" . $languages_id . "' left join " . TABLE_SPECIALS . " s on p.products_id = s.products_id where products_status = '1' and week(p.products_date_available) = week(now()) order by p.products_date_available DESC, pd.products_name";



First of all, is this the correct sql for pulling products that are available for the current week?


Next, how do I change the template parameters so that the main page displays all products available for the given week? I had thought that MAX_DISPLAY_PRODUCTS_NEW handled this, and at one point I had deleted all mention of it out of /catalog/products_new.php but I ended up creating errors on the page you access from 'What's New" link from the left hand column. I then restored all the MAX_DISPLAY_PRODUCTS_NEW parameters I removed earlier.


Can someone help me out here and point out how I can handle this? Thanks.

Link to comment
Share on other sites

  • 10 months later...


This topic is now archived and is closed to further replies.

  • Create New...