Gossamer Forum
Home : Products : Gossamer Links : Version 1.x :

Re: Changing COOL sort to 'hits' only

Quote Reply
Re: Changing COOL sort to 'hits' only In reply to
you could make it just do this:

Code:
$total = 0;
while ($link = $sth->fetchrow_hashref) {
$total++;
$link_results .= &site_html_link ($link);
}

and of course comment out those other lines..

then up a few lines..

ABOVE:

Code:
LIMIT 1000

add

Code:
ORDER BY Links.Hits DESC

or you can just change the whole prepare statement to

SELECT * FROM Links WHERE isPopular = 'Yes' ORDER BY Hits DESC LIMIT 1000

jerry
Subject Author Views Date
Thread Changing COOL sort to 'hits' only pugdog 3050 Oct 18, 1999, 7:48 PM
Post Re: Changing COOL sort to 'hits' only
widgetz 2968 Oct 18, 1999, 8:14 PM
Post Re: Changing COOL sort to 'hits' only
pugdog 2968 Oct 18, 1999, 10:55 PM
Post Re: Changing COOL sort to 'hits' only
Alex 2969 Oct 19, 1999, 6:55 AM
Post Re: Changing COOL sort to 'hits' only
pugdog 2965 Oct 19, 1999, 8:16 AM
Post Re: Changing COOL sort to 'hits' only
widgetz 2967 Oct 19, 1999, 11:06 AM
Post Re: Changing COOL sort to 'hits' only
pugdog 2968 Oct 19, 1999, 12:30 PM
Post Re: Changing COOL sort to 'hits' only
pugdog 2970 Dec 22, 1999, 12:06 AM