<p>This StackExchange question explains how to set an array of IDs for items in your cart, and then compare those IDs against the IDs of a list of products: <a href="https://craftcms.stackexchange.com/questions/17005/check-if-cart-contains-valid-products-for-discount-code">Check if cart contains valid products for discount code</a></p>

CC BY-SA 3.0
2017-05-15T03:04:35.583Z
2017-05-15T03:04:35.583Z
Matt Everson
<p>Is it possible to show the complete products list, but indicate which products are already in the cart? What's the conditional?</p>

<plugin-craftcommerce>
How do I check and indicate that a product is already in the cart?
# How do I check and indicate that a product is already in the cart?

(Asked by: username_0 on 2017-04-14)

Is it possible to show the complete products list, but indicate which products are already in the cart? What's the conditional?

**Tags:** plugin-craftcommerce


---

## 1 answers

### Answer by username_0 on 2017-05-15. Score: 2 | Accepted answer

This StackExchange question explains how to set an array of IDs for items in your cart, and then compare those IDs against the IDs of a list of products: [Check if cart contains valid products for discount code](https://craftcms.stackexchange.com/questions/17005/check-if-cart-contains-valid-products-for-discount-code)


---

