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)
-   -   Sorry, Sold out sign? (https://forum.x-cart.com/showthread.php?t=467)

japanchick 10-29-2002 10:53 AM

Sorry, Sold out sign?
 
Hi!

I recently did a test order on my x-cart to see what would happen if you made a purchase, with the quantity at zero. Apparently, a sold out sign doesnt show up. Instead, when you click the add cart button, the screen just refreshes.

Is there anyway I can add a sold out page that appears when there are no more items left? I dont like to display the how many items I have left on the product description page as it doesnt go with the flow of my site..

thanks for your help!

japanchick

Jeannie 10-29-2002 11:54 AM

See if this is what you want it to do...
http://www.mobile-audio.net/store/customer/product.php?productid=17733&cat=495&page=1
Shows as sold out and cannot be added to cart.

And items that are In Stock do not show how many are available.

Wasn't sure what you meant by sold out page. If this works for what you want, I'll dig around for what I did and hope it works in later versions.

japanchick 10-29-2002 12:18 PM

Wow!
 
Thats looks great! Can I possible get the code? THanks!

Jeannie 10-29-2002 12:45 PM

Keep in mind this worked in v3.1.1 so I'd recommend commenting out lines in the tpl's instead of removing them

To get "sold out" on 0 availability products:
skin1.conf
Code:

UnlimitedProducts = "N"

And in customer/main/product.tpl:
comment out this piece to remove the quantity of stock available from being shown

Code:

{if #UnlimitedProducts# ne "Y" and $product.distribution eq ""}
<tr><td width=30%>{$lng.lbl_quantity}</td><td nowrap>{if $product.avail gt 0}{$product.avail}{else}{$lng.txt_no}{/if} {$lng.txt_items_available}</td></tr>
{/if}


Hope it works for you!


All times are GMT -8. The time now is 02:11 PM.

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