There's a big difference when using:

$_cartQty = $this->getSummaryCount();


$_cartQty = Mage::helper('checkout/cart')->getCart()->getItemsCount();

Results are totally different (12 vs 4).

The same when inspecting the elements using:

$_items = $this->getRecentItems();


$_items = Mage::helper('checkout/cart')->getCart()->getItems();

Why is that?

1 Answer 1


Minicart or sidebar cart does not show all the items added to cart, where as it shows the last few recent items there.

So basically $this->getSummaryCount(); or $this->getRecentItems(); in particular phtml gives you the items to show in sidebar.

Where as cart gives you all items.

You can define the max number through system config. Go to, System > Configuration > Sales > Checkout > Shopping Cart Sidebar > Maximum Display Recently Added Item(s)

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.