View Single Post
  #8  
Old 01-18-2018, 11:50 AM
  cflsystems's Avatar 
cflsystems cflsystems is offline
 

Veteran
  
Join Date: Apr 2007
Posts: 14,190
 

Default Re: Page for products with list price < price

List price is attached to the product and not to variant. As far as I know it is there at all times - as long as there is product array available on the page.

You can do the foreach to list products in smarty with condition however if you do not need these products on the page it is way better and faster to strip them out in php.

Either use func_search_products (you can see an example of it in bestsellers module) so you can have the query restrictions set there OR do foreach and unset product after you run the search.php in your scrip (since you said it is based on products.php).

I would redo the script and use func_search_products - it is faster and collects just the necessary info which you can add to if you need more after that.

Then in the smarty template just do foreach loop and list the products
__________________
Steve Stoyanov
CFLSystems.com
Web Development
Reply With Quote