[pLog-svn] r526 - plog/trunk/class/summary/dao
Oscar Renalias
oscar at renalias.net
Fri Dec 17 18:34:59 GMT 2004
good one! I hadn't noticed this bug...
I'm sooooo glad that there is finally somebody with knowledge and
attitude here helping me!!! :-)
Thanks!
Oscar
On 17 Dec 2004, at 18:21, subaochen at devel.plogworld.net wrote:
> Author: subaochen
> Date: 2004-12-17 16:21:06 +0000 (Fri, 17 Dec 2004)
> New Revision: 526
>
> Modified:
> plog/trunk/class/summary/dao/summarystats.class.php
> Log:
> fix getMostActiveBlogs: check blog status to only show the active blogs
>
>
> Modified: plog/trunk/class/summary/dao/summarystats.class.php
> ===================================================================
> --- plog/trunk/class/summary/dao/summarystats.class.php 2004-12-17
> 15:35:29 UTC (rev 525)
> +++ plog/trunk/class/summary/dao/summarystats.class.php 2004-12-17
> 16:21:06 UTC (rev 526)
> @@ -254,8 +254,9 @@
> $prefix = $this->getPrefix();
> $query = "SELECT COUNT(*) as t, SUM((num_reads /
> (TO_DAYS(NOW()) - TO_DAYS(a.date) + 1)) ) as rank, b.*
> FROM {$prefix}articles AS a
> - INNER JOIN {$prefix}blogs AS b ON
> b.id=a.blog_id
> - GROUP BY a.blog_id ORDER BY rank DESC ";
> + INNER JOIN {$prefix}blogs AS b
> + ON b.id=a.blog_id AND
> b.status=".BLOG_STATUS_ACTIVE.
> + " GROUP BY a.blog_id ORDER BY rank DESC ";
>
> if( $maxBlogs > 0 )
> $query .= " LIMIT 0,".$maxBlogs;
>
> _______________________________________________
> pLog-svn mailing list
> pLog-svn at devel.plogworld.net
> http://devel.plogworld.net/mailman/listinfo/plog-svn
>
More information about the pLog-svn
mailing list