Forums / Templates, Stylesheets, Page Layout / New products shows newest first - how?

New products shows newest first - how?

Locked

Started by azeela on 12 Apr 2008, 8:37 AM · Views: 2,536

Results 1 to 5 of 5
This thread is locked. New replies are disabled.
12 Apr 2008, 8:37 AM
#1
azeela avatar

azeela

New Zenner

Join Date:
Apr 2008
Posts:
79
Plugin Contributions:
0

New products shows newest first - how?

Hi all.. :D

Is there any way to make my newest new product first on my new product list?

I can understand that the list is random when I've added multiple products at the same date, but now I added a single product in the believe that it would appear first, but it doesnt?
Could it do that?

Hugs..
Sine
My store-to-be..

12 Apr 2008, 8:53 AM
#2
kuroi avatar

kuroi

Totally Zenned

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

Re: New products shows newest first - how?

Azeela:

Hi all.. :D

Is there any way to make my newest new product first on my new product list?

I can understand that the list is random when I've added multiple products at the same date, but now I added a single product in the believe that it would appear first, but it doesnt?
Could it do that?You haven't said which new product list. There are three, the side box, the listing box on the home page (and others) and the new products listing page.

In each case you would need to re-write the database query that extracts the data to order it by date added, and then re-write the PHP that steps through the list to remove the randomising.

Kuroi Web Design and Development | Twitter

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

12 Apr 2008, 9:10 AM
#3
azeela avatar

azeela

New Zenner

Join Date:
Apr 2008
Posts:
79
Plugin Contributions:
0

Re: New products shows newest first - how?

It's the box on my mainpage with just one product that's the most important. Well my sidebox thing will probably follow I guess, but it's the one in the main area that concerns me the most.

But where do I find where to rewrite what you said?

Hugs..
Sine
My store-to-be..

12 Apr 2008, 9:53 AM
#4
kuroi avatar

kuroi

Totally Zenned

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

Re: New products shows newest first - how?

Oh but you are so in luck. The specific change that you would need to make to achieve what you want is very easy indeed. You would over-ride your includes/modules/new_products.php file and in your copy would change this line (near the top)> $display_limit = zen_get_new_date_range();to be this> $display_limit = ' order by p.products_date_added desc limit 1';

Kuroi Web Design and Development | Twitter

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

12 Apr 2008, 10:36 AM
#5
azeela avatar

azeela

New Zenner

Join Date:
Apr 2008
Posts:
79
Plugin Contributions:
0

Re: New products shows newest first - how?

Wohoo!!! Thanks SO much!!

Hugs..
Sine
My store-to-be..