Jump to content

Display "SOLD OUT" span on category page if qty = 0


Recommended Posts

Hi all is this possible?

 

I want to add a "SOLD OUT" span on category product-list.

 

I have this code:

 

 

{if isset($product.available_for_order) && ($product.quantity == 0)}<span class="offmenu">{l s='SOLD OUT'}</span>{/if}

 

 

This works for items with no combinations. However, if I have a suit with multiple sizes then if hte default size is out of stock, the product will appear as "SOLD OUT" even if there are other sizes available.

 

Is this possible?>

 

Thanks in advance

Link to comment
Share on other sites

×
×
  • Create New...