views:

250

answers:

1

Hi all, I'm currently using Magento ver 1.1.6. My store only sells unique items (shirts with exclusive designs) which means at any one time, only 1 unit is available for each items.

How do I omit those items which are already sold from being displayed in the front page?

BTW, I'm using these code to show products on the front page:

{{block type="catalog/product_list" category_id="3" template="catalog/product/list_home_batik.phtml"}}
A: 

I supposed the file catalog/product/list_home_batik.phtml is based on catalog/product/list.phtml

You can modify the file catalog/product/list_home_batik.phtml by adding

<?php if($_product->isSaleable()): ?>

just after

<?php foreach ($_productCollection as $_product): ?>

and by adding

<?php foreach ($_productCollection as $_product): ?>

just before

<?php endforeach; ?>

If it doesn't work, you should provide the complete file so I can have a look at it.

stunti