X-Cart: shopping cart software

X-Cart forums (https://forum.x-cart.com/index.php)
-   Changing design (https://forum.x-cart.com/forumdisplay.php?f=51)
-   -   In/out of stock (https://forum.x-cart.com/showthread.php?t=40851)

abeight 07-01-2008 12:44 PM

In/out of stock
 
I want to add a graphic on the product listing that shows whether a product is in or out of stock. I've tried grabbing some snippets of code from the buy_now.tpl file, but they don't seem to work. Does anyone know off hand what the if statement is that says whether a product is in stock on this page?

I also tried {if $product.avail gt 0}, but that only seems to work on the detail page.

V 4.1.10

Here's my sample page: http://www.gamesuave.com/xcart2/home.php?cat=23

Thanks!

balinor 07-01-2008 12:45 PM

Re: In/out of stock
 
{if $products[product].avail gt 0}

abeight 07-01-2008 12:48 PM

Re: In/out of stock
 
Awesome, thank you very much! :)


All times are GMT -8. The time now is 04:25 PM.

Powered by vBulletin Version 3.5.4
Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.