Jump to content

i have the attribute id and product id how to get the quantity of the cart products


ganeshgp

Recommended Posts

You can use

 

$cart->getProducts(false,id_prod);

 

 

then you'll have the resultset with the id_product_attributes and quantities for each combination of this product in the cart

 

The $cart variable is available in a multiple ways. For example Context::getContext()->cart;

Edited by Enrique Gómez (see edit history)
  • Like 1
Link to comment
Share on other sites

only I don't understand what ganeshgp exactly expect?

You want to check quantities of product added to cart?

where you want to check it? in some module? controller? 

i need in  ajax_cart.js file with included in  blockcart module..

 

thanks

Link to comment
Share on other sites

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 account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...