Gossamer Forum
Home : Products : DBMan : Discussions :

Whats New - What's New sort order

Quote Reply
Whats New - What's New sort order
Hi all

I have the What's New mod installed and working well, however how I would like to sort the results with the most recent added at the top of the list as at present all records added on the same day do not seem to sort by date(time). ( PS I am pulling the records in via SSI)

I have tried adding
&$db_key=*&so=descend&sb=0
into by virtual SSI call, thinking that the key field would be the best place to start ..but without any joy - infact it does not touch the results with ascend or descend selected.

I think that this may be to do with the hard coding of the order within the db.cgi by this part of the mod
this is under sub query

# Added by PJO for Whats new START

if($in{'listnew'}) {
$days = 6; # Number of days for What's New, +1.
$new = &get_date(time() - ($days * 86400));

# Change Date below to match the *exact* name of your date field.
$in{'Date-gt'} = $new;

# Change 2 below to match the number of your date field.
$in{'sb'} = 2; # Number of your date field

$in{'so'} = 'descend';
}

i.e. the script is sorting once already and I cannot therefore sort by another field.

Is there a way of either sorting 'by time by date' or including the key field sort in there somewhere.

Thanks all


Subject Author Views Date
Thread Whats New - What's New sort order PhilOwen 2638 Apr 2, 2001, 11:12 AM
Post Re: Whats New - What's New sort order
Bearwithme 2535 Apr 2, 2001, 11:31 AM