cancel
Showing results for 
Search instead for 
Did you mean: 

MIni card - How i can show only last 4 products?

MIni card - How i can show only last 4 products?

Hi all!

In header top of  my web site i put in a mini shopping bag. Well... i want to show only last 4 products.

How i can do? I think to modify the "for each" ? Where is?

Thanks

Ale

2 REPLIES 2

Re: MIni card - How i can show only last 4 products?

Hi @pig_org 

 

I think you are looking for the sidebar cart block. Depending on your template this can varie but it should be located in:

 

checkout/cart/sidebar.phtml

 

within your template. By default the block uses getRecentItems to fetch the latest 3 items, you can however change this by getItems to get all the items and just slice the array to your liking. You can also get the block to do that for you using the layout:

 

    <default>
        <reference name="minicart_content">
            <action method="setItemCount"><count>4</count></action>
        </reference>
    </default>

 

If you are new to Magento i recommend reading up on the layout here:

 

http://www.magentocommerce.com/knowledge-base/entry/magento-for-dev-part-4-magento-layouts-blocks-an...

 

I hope this helps :-)

Re: MIni card - How i can show only last 4 products?

I put 4 product in

system > configuration > checkout > sidebar > sidebar "no" and recent 4 but not work

My mini cart is very large! i see all the product, not only 4 recent product.

Where is the xml file configuration of mini card?

Where is the "each for" cicle of mini cart?

Thanks

Ale