X-Git-Url: http://git.shiar.nl/minimedit.git/blobdiff_plain/7213175b8391e8f47f54096fada4fdc33d82b8a1..217f7dc706236f1edbff198893b54f3518742879:/widget/login/list.php diff --git a/widget/login/list.php b/widget/login/list.php index 698b805..0500ef2 100644 --- a/widget/login/list.php +++ b/widget/login/list.php @@ -1,6 +1,8 @@ place[0])) { + $basepath .= '/.tags/' . $Page->place[0]; +} $users = glob("$basepath/*/"); if (!$users) return; @@ -8,8 +10,8 @@ foreach ($users as $col => $userdir) { $users[$col] = new User($userdir); } -if (isset($Place['order'])) { - $ordercol = $Place['order']; +if (isset($Page->place['order'])) { + $ordercol = $Page->place['order']; $order = array_map(function ($row) use ($ordercol) { return $row->$ordercol; }, $users); @@ -23,12 +25,12 @@ if (isset($Place['order'])) { } } -if (isset($Place['n'])) { - array_splice($users, $Place['n']); # limit number of results +if (isset($Page->place['n'])) { + array_splice($users, $Page->place['n']); # limit number of results } print 'place['view'] == 'avatar') { print ' class="gallery cat"'; } elseif (count($users) > 5) { @@ -37,13 +39,13 @@ elseif (count($users) > 5) { print ">\n"; foreach ($users as $user) { - $name = $user->name ?: $user->login; - if ($GLOBALS['User'] and $GLOBALS['User']->admin) { + $name = $user->html; + if ($GLOBALS['User'] and $GLOBALS['User']->admin('user')) { $link = '/login/edit/'.$user->login; $name = sprintf('%s', $link, $name); } - switch (@$Place['view']) { + switch (@$Page->place['view']) { case 'avatar': if (!file_exists("{$user->dir}/avatar.jpg")) { break;