4 * GForge Top-Statistics: Most active Users
6 * Copyright 1999-2000 (c) The SourceForge Crew
7 * The rest Copyright 2002-2004 (c) GForge Team
10 * This file is part of GForge.
12 * GForge is free software; you can redistribute it and/or modify
13 * it under the terms of the GNU General Public License as published by
14 * the Free Software Foundation; either version 2 of the License, or
15 * (at your option) any later version.
17 * GForge is distributed in the hope that it will be useful,
18 * but WITHOUT ANY WARRANTY; without even the implied warranty of
19 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
20 * GNU General Public License for more details.
22 * You should have received a copy of the GNU General Public License
23 * along with GForge; if not, write to the Free Software
24 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
27 require ('../env.inc.php');
28 require $gfwww.'include/pre.php';
29 require_once $gfcommon.'include/Stats.class.php';
31 $offset = getIntFromRequest('offset');
32 $type = getStringFromRequest('type');
33 $limit = getStringFromRequest('limit');
35 if (!$offset || $offset < 0) {
39 if ($type == 'week') {
40 $title = _('Most Active This Week');
42 $title = _('Most Active All Time');
45 $HTML->header(array('title'=>$title));
47 print '<p><h3>'.$title.'</h3>
48 <br /><em>('._('Updated Daily').')</em>
50 <p>'.util_make_link ('/top/','['._('View Other Top Categories').']');
52 $arr=array(_('Rank'),_('Project name'),_('Percentile'));
54 echo $HTML->listTableTop($arr);
57 $res_top = $stats->getMostActiveStats($type, $offset);
58 $rows=db_numrows($res_top);
61 while ($row_top = db_fetch_array($res_top)) {
64 <tr '. $HTML->boxGetAltRowStyle($i) .'>
65 <td> '.$i.'
67 <td>'.util_make_link_g (strtolower($row_top['unix_group_name']),$row_top['group_id'],$row_top['group_name']).'
69 <td align="right">'.substr($row_top['percentile'],0,5).'%</td>
76 <tr class="tablegetmore">
77 <td>'.util_make_link ('/top/mostactive.php?type='.$type.'&offset='.($offset-$LIMIT),'<strong><-- '._('More').'</strong>');
84 <td align="RIGHT">'.util_make_link ('/top/mostactive.php?type='.$type.'&offset='.($offset+$LIMIT),'<strong>'._('More').' --></strong>').'
89 echo $HTML->listTableBottom();
91 $HTML->footer(array());
95 // c-file-style: "bsd"