diff options
Diffstat (limited to 'core/include/user')
-rw-r--r-- | core/include/user/list.php | 13 |
1 files changed, 11 insertions, 2 deletions
diff --git a/core/include/user/list.php b/core/include/user/list.php index afc8179..72375a4 100644 --- a/core/include/user/list.php +++ b/core/include/user/list.php @@ -30,8 +30,17 @@ if(Application::get('USER.SINGLE_REDIRECT') === TRUE AND $count === '1') { HTTP::redirect($User->getURL()); } -$execSQL = "SELECT id FROM %s ORDER BY {$site_sort} LIMIT ".(($currentSite-1) * $site_size).", {$site_size}"; -$userIDs = $Database->query(sprintf($execSQL, User\Attribute::TABLE))->fetchAll($Database::FETCH_COLUMN); +$execSQL = "SELECT * FROM %s ORDER BY {$site_sort} LIMIT ".(($currentSite-1) * $site_size).", {$site_size}"; +$Statement = $Database->query(sprintf($execSQL, User\Attribute::TABLE)); + +while($Attribute = $Statement->fetchObject('User\Attribute')) { + try { + $User = User\Factory::buildByAttribute($Attribute); + $ItemTemplate = generateUserItemTemplate($User); + + $users[] = $ItemTemplate; + } catch(User\Exception $Exception){} +} foreach($userIDs as $userID) { try { |