nitrorc Posted February 28, 2007 Share Posted February 28, 2007 Does anyone know how to to display a special price in the cart only? Due to some of our products having a minimum advertised price, we cannot show that price on a main page. I've seen some pages where if you add it to the cart it gives you the sales price and it gets around the manufactures MAP. I searched the contributions and couldn't find anything. I found a call for price and a click for price where you have to make contact directly with the customer but it's not what I'm looking for. Thanks :thumbsup: When you have eliminated the impossible, whatever remains, however improbable, must be the truth. -Sherlock Holmes Link to comment Share on other sites More sharing options...
Guest Posted March 1, 2007 Share Posted March 1, 2007 you have to change the catalog\includes\classes\shopping_cart.php You check if the product is a special one (probably via some database field or using the specials table) and then you store a field with the products array so the catalog\shopping_cart.php can display this special price. Link to comment Share on other sites More sharing options...
nitrorc Posted March 2, 2007 Author Share Posted March 2, 2007 Thanks for responding so quickly! I was thinking about your suggestion and do you think it would be better to modify the specials function or create a new function to call in the shopping cart, or should I code it right in the cart itself? Most likely if the price is below advertised, it will be in the specials category anyway. When you have eliminated the impossible, whatever remains, however improbable, must be the truth. -Sherlock Holmes Link to comment Share on other sites More sharing options...
Guest Posted March 2, 2007 Share Posted March 2, 2007 you could do either way. there is a function already in the general.php //// // Return a product's special price (returns nothing if there is no offer) // TABLES: products function tep_get_products_special_price($product_id) { $product_query = tep_db_query("select specials_new_products_price from " . TABLE_SPECIALS . " where products_id = '" . (int)$product_id . "' and status"); $product = tep_db_fetch_array($product_query); return $product['specials_new_products_price']; } which you could utilize. Either duplicate it or use it directly. Link to comment Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.