Forums / Setting Up Categories, Products, Attributes / hide products out of stock

hide products out of stock

Locked

Started by balihr on 30 Dec 2008, 12:30 PM · Views: 4,332

Results 1 to 7 of 7
This thread is locked. New replies are disabled.
30 Dec 2008, 12:30 PM
#1
balihr avatar

balihr

Totally Zenned

Join Date:
Oct 2008
Location:
Croatia
Posts:
1,811
Plugin Contributions:
22

hide products out of stock

hy everyone!

i would like to hide products that are out of stock so my customers can't see it. I have a lot of products that are out of stock and it can get very annoying searching for one product between ten out of stock items.

i've tried config -> stock -> Product status...when out of stock -> set to 0. This doesn't work, I still see those products on my site.

I don't know if it is relevant - products that are out of stock have qty=0, and are displayed as Sold Out.

site is www.bali.hr

best example for my problem is this

My site - Pro ZC Help
My portfolio | My plugins

30 Dec 2008, 12:43 PM
#2
kuroi avatar

kuroi

Totally Zenned

Join Date:
Apr 2006
Location:
London, UK
Posts:
10,475
Plugin Contributions:
11

Re: hide products out of stock

What version of Zen Cart are you using?

Kuroi Web Design and Development | Twitter

(Questions answered in the forum only - so that any forum member can benefit - not by personal message)

30 Dec 2008, 12:50 PM
#3
balihr avatar

balihr

Totally Zenned

Join Date:
Oct 2008
Location:
Croatia
Posts:
1,811
Plugin Contributions:
22

Re: hide products out of stock

c/p

Zen Cart 1.3.8a
Database Patch Level: 1.3.8
v1.3.8 [2008-11-04 23:20:42] (Fresh Installation)
v1.3.8 [2008-11-04 23:20:42] (Fresh Installation)

My site - Pro ZC Help
My portfolio | My plugins

30 Dec 2008, 1:32 PM
#4
kuroi avatar

kuroi

Totally Zenned

Join Date:
Apr 2006
Location:
London, UK
Posts:
10,475
Plugin Contributions:
11

Re: hide products out of stock

That config setting will only set the status to zero on products that go out of stock after the setting is changed. Could the products still showing have gone out of stock before you changed the setting?

If so, you would need to update the product status manually on them, either by going into each one to change the status, or by running the following SQL patch through Admin > Tools > Install SQL Patches utility (after backing up your database first)

update products set products_status = 0 where products_quantity <= 0;

Kuroi Web Design and Development | Twitter

(Questions answered in the forum only - so that any forum member can benefit - not by personal message)

30 Dec 2008, 3:40 PM
#5
balihr avatar

balihr

Totally Zenned

Join Date:
Oct 2008
Location:
Croatia
Posts:
1,811
Plugin Contributions:
22

Re: hide products out of stock

:clap::clap::clap:

you're my idol! after executing your patch, it's just like i wanted it!

i didn't know it matters that the products have gone out of stock before setting that option...

thank you very very much !!!

My site - Pro ZC Help
My portfolio | My plugins

16 Jun 2010, 4:12 PM
#6
andi98640 avatar

andi98640

New Zenner

Join Date:
Jan 2010
Posts:
62
Plugin Contributions:
0

Re: hide products out of stock

I am so glad this message was here!
I have searched and searched for this solution!
Thanks so much, it should be stickied!

18 Jun 2010, 9:45 PM
#7
chrx avatar

chrx

New Zenner

Join Date:
Aug 2005
Location:
SF Bay Area, California, USA
Posts:
84
Plugin Contributions:
0

Re: hide products out of stock

Ecxellent! Thank you.
chrx