mcluca Posted November 13, 2013 Share Posted November 13, 2013 Hi everyone! Is there a way to insert a specific function in cart.php that automatic add specific product to cart if total cart pass certain amount. Example if >100€ add product id=1. What function i can use to add product in cart after (if total price) condition? Thanks Link to comment Share on other sites More sharing options...
vekia Posted November 13, 2013 Share Posted November 13, 2013 you can do it in CartController inside public function add(). you will need to check total cart amount, and after that - add new product with the same function Link to comment Share on other sites More sharing options...
mcluca Posted November 13, 2013 Author Share Posted November 13, 2013 thanks I have PS 1.4 and in CartController i have found /* Product addition to the cart */ if (!isset(self::$cart->id) OR !self::$cart->id) { self::$cart->add(); if (self::$cart->id) self::$cookie->id_cart = (int)(self::$cart->id); } how can add product with this? or i must creat public function to add product to cart Link to comment Share on other sites More sharing options...
mcluca Posted November 26, 2013 Author Share Posted November 26, 2013 hi. i can't do. Please can you give me a suggestion to automatic add product in cart if condition is true. Thanks Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now