Forums / General Questions / New Products with sold out

New Products with sold out

Locked

Views: 2,333

Results 1 to 11 of 11
This thread is locked. New replies are disabled.
16 Jan 2008, 6:22 AM
#1
boghead avatar

boghead

New Zenner

Join Date:
Oct 2007
Posts:
21
Plugin Contributions:
0

New Products with sold out

I want to show out of stock items with the sold out warning when looking at products in a category of the shop but I also get sold out products in the New Products listing page.

Is there a way to only show in stock products in the New Products pages?

Thanks.

16 Jan 2008, 7:51 AM
#2
kobra avatar

kobra

Black Belt

Join Date:
Aug 2005
Location:
Arizona
Posts:
31,500
Plugin Contributions:
4

Re: New Products with sold out

You would have to custom code this in stock check into the new products and whats new files

Zen-Venom Get Bitten

16 Jan 2008, 8:57 AM
#3
absolute avatar

absolute

Totally Zenned

Join Date:
May 2005
Location:
Bath, Somerset
Posts:
1,054
Plugin Contributions:
2

Re: New Products with sold out

BACK UP FIRST!

edit includes/modules/pages/products_new/header_php.php

Add

and p.products_quantity > 0 

after

WHERE p.products_status = 1
AND p.products_id = pd.products_id

which is found on around lines 30 - 31

Make sure you back this file up, as there is no override system for this folder!

Absolute

Back, after a 4 year absence! Did you miss me?
Absolute Web Solutions Ltd
Interested in our work? Take a look at one of our sites - The Tech Store

17 Jan 2008, 3:55 AM
#4
boghead avatar

boghead

New Zenner

Join Date:
Oct 2007
Posts:
21
Plugin Contributions:
0

Re: New Products with sold out

Excellent,
Thanks

21 Jan 2008, 4:13 AM
#5
wtashby avatar

wtashby

Totally Zenned

Join Date:
Feb 2006
Posts:
594
Plugin Contributions:
0

Re: New Products with sold out

I tried this fix, but it made no difference at all. I am still getting sold out (zero quantity) showing up in New Products.

I Think, Therefore I Zen. I Zen, Therefore, I AM!
Personalized Flowers!
Flowertown Speaking Roses
using version 1.5.7-06232020

21 Jan 2008, 7:46 AM
#6
absolute avatar

absolute

Totally Zenned

Join Date:
May 2005
Location:
Bath, Somerset
Posts:
1,054
Plugin Contributions:
2

Re: New Products with sold out

This fix will only remove teh sold out products from the New Products page - not the New Products box which appears in various locations within the store. Is this where the sold out products are appearing?

Absolute

Back, after a 4 year absence! Did you miss me?
Absolute Web Solutions Ltd
Interested in our work? Take a look at one of our sites - The Tech Store

21 Jan 2008, 12:15 PM
#7
wtashby avatar

wtashby

Totally Zenned

Join Date:
Feb 2006
Posts:
594
Plugin Contributions:
0

Re: New Products with sold out

The phantom new products are showing up in the new products for "month" boxes that show up when you click catagories and sub catagories. The do Not appear when you click the New Products link.

I Think, Therefore I Zen. I Zen, Therefore, I AM!
Personalized Flowers!
Flowertown Speaking Roses
using version 1.5.7-06232020

21 Jan 2008, 2:23 PM
#8
absolute avatar

absolute

Totally Zenned

Join Date:
May 2005
Location:
Bath, Somerset
Posts:
1,054
Plugin Contributions:
2

Re: New Products with sold out

For that box, you would need to edit includes/modules/YOUR_TEMPLATE/new_products.php

Add the following code to the SQL starting line 23 ater and pd.language_id = '" . (int)$_SESSION['languages_id'] . "'

and p.products_quantity > 0

That's it.

Absolute

Back, after a 4 year absence! Did you miss me?
Absolute Web Solutions Ltd
Interested in our work? Take a look at one of our sites - The Tech Store

21 Jan 2008, 11:54 PM
#9
wtashby avatar

wtashby

Totally Zenned

Join Date:
Feb 2006
Posts:
594
Plugin Contributions:
0

Re: New Products with sold out

Nope. That didn't work. Sorry.

Just to reiterate, I am talking about the New Products for "month" box that shows up when you click on a catagory, or sub catagory. IE: New Products for January

Nothing I've done, short of actually deleting the product, has removed it from that box.

I Think, Therefore I Zen. I Zen, Therefore, I AM!
Personalized Flowers!
Flowertown Speaking Roses
using version 1.5.7-06232020

22 Jan 2008, 9:06 AM
#10
absolute avatar

absolute

Totally Zenned

Join Date:
May 2005
Location:
Bath, Somerset
Posts:
1,054
Plugin Contributions:
2

Re: New Products with sold out

That's the file you need to edit. Have you placed it in your active template folder, or in a folder called YOUR_TEMPLATE?

Absolute

Back, after a 4 year absence! Did you miss me?
Absolute Web Solutions Ltd
Interested in our work? Take a look at one of our sites - The Tech Store

22 Jan 2008, 12:13 PM
#11
wtashby avatar

wtashby

Totally Zenned

Join Date:
Feb 2006
Posts:
594
Plugin Contributions:
0

Re: New Products with sold out

I figured out what I did wrong. You said to put the code in the section starting at line 23. However that is the section for manufactureres. A little further down, around line 41 where it says $new_products_query is the section to put the line in. I put it there, and now it works perfectly.

Thanks very much for your help.

I Think, Therefore I Zen. I Zen, Therefore, I AM!
Personalized Flowers!
Flowertown Speaking Roses
using version 1.5.7-06232020