Not for official support
We do not provide technical support in this forum.
If you want to contact our customer support, please use our support form.

Take the chance to buy
Shop-Script 5 at the low price
Save $30 only until May 31!
Your last chance!
8 days left

You are not logged in.

#1 2012-05-04 01:53

marknotton
Member

Get stock information for lists

So I've played around with how list items get displayed. But I can't seem to find out the products stock.

To get the other basic information I use this: {$_product.price_str}, so naturally I tried {$_product.stock_str}. But it doesn't work.

I also tried:

Code:

{if $product_info.ordering_available && $product_info.Price>0 && ( $smarty.const.CONF_CHECKSTOCK==0 || $product_info.in_stock > 0 ) }
    Stock: yes   
{else}
    Stock: no   
{/if}

Which also doesn't work. All I need to do is get a "yes" or "no" (or true/false) answer to wether stock is available for that particular item from the list.

Any ideas?

Offline

 

#2 2012-05-06 04:17

rat
Administrator

Re: Get stock information for lists

Add the following string to your template:

Code:

{debug}

This will open a pop-up window when you try to open a page. All available variables will be displayed in that pop-up window.


Be careful what you wish for — you might get it.

Offline

 

Board footer

Powered by PunBB