Skip to content

Commit

Permalink
Changed the registered user count in index.php to not include unverif…
Browse files Browse the repository at this point in the history
…ied users. Changed userlist.php not to list unverified users.

Altered extern.php to also only show verified users in the stats.
Imported from FluxBB.

git-svn-id: http://punbb.informer.com/svn/punbb/branches/punbb-1.3-dev@756 4dc816b1-62af-4023-b237-cae3452c1eb1
  • Loading branch information
Anatoly authored and Anatoly committed Oct 30, 2008
1 parent d78ca1b commit 9be40fb
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 7 deletions.
6 changes: 4 additions & 2 deletions upload/extern.php
Original file line number Diff line number Diff line change
Expand Up @@ -514,8 +514,9 @@ function output_html($feed)

// Collect some statistics from the database
$query = array(
'SELECT' => 'COUNT(u.id)-1',
'FROM' => 'users AS u'
'SELECT' => 'COUNT(u.id) - 1',
'FROM' => 'users AS u',
'WHERE' => 'u.group_id != '.FORUM_UNVERIFIED
);

($hook = get_hook('ex_qr_get_user_count')) ? eval($hook) : null;
Expand All @@ -525,6 +526,7 @@ function output_html($feed)
$query = array(
'SELECT' => 'u.id, u.username',
'FROM' => 'users AS u',
'WHERE' => 'u.group_id != '.FORUM_UNVERIFIED,
'ORDER BY' => 'u.registered DESC',
'LIMIT' => '1'
);
Expand Down
5 changes: 3 additions & 2 deletions upload/index.php
Original file line number Diff line number Diff line change
Expand Up @@ -261,8 +261,9 @@

// Collect some statistics from the database
$query = array(
'SELECT' => 'COUNT(u.id)-1',
'FROM' => 'users AS u'
'SELECT' => 'COUNT(u.id) - 1',
'FROM' => 'users AS u',
'WHERE' => 'u.group_id != '.FORUM_UNVERIFIED
);

($hook = get_hook('in_stats_qr_get_user_count')) ? eval($hook) : null;
Expand Down
6 changes: 3 additions & 3 deletions upload/userlist.php
Original file line number Diff line number Diff line change
Expand Up @@ -42,9 +42,9 @@

// Fetch user count
$query = array(
'SELECT' => 'COUNT(u.id)',
'SELECT' => 'COUNT(u.id) - 1',
'FROM' => 'users AS u',
'WHERE' => 'u.id>1'
'WHERE' => 'u.group_id != '.FORUM_UNVERIFIED
);

if (!empty($where_sql))
Expand Down Expand Up @@ -220,7 +220,7 @@
'ON' => 'g.g_id=u.group_id'
)
),
'WHERE' => 'u.id>1',
'WHERE' => 'u.id > 1 AND u.group_id != '.FORUM_UNVERIFIED,
'ORDER BY' => $forum_page['sort_by'].' '.$forum_page['sort_dir'].', u.id ASC',
'LIMIT' => $forum_page['start_from'].', 50'
);
Expand Down

0 comments on commit 9be40fb

Please sign in to comment.