- function compare($a, $b)
- {
- if ($a['promo'] == $b['promo']) {
- if ($a['nom'] == $b['nom']) {
- return strcmp($a['prenom'], $b['prenom']);
- }
- return strcmp($a['nom'], $b['nom']);
- }
- return $a['promo'] - $b['promo'];
- }
-
- function _get_list($offset, $limit)
- {
- global $platal;
- list($total, $members) = $this->client->get_members_limit($platal->argv[1], $offset, $limit);
-
- $membres = Array();
- foreach ($members as $member) {
- list($m) = explode('@',$member[1]);
- $res = XDB::query("SELECT prenom,if (nom_usage='', nom, nom_usage) AS nom,
- promo, a.alias AS forlife
- FROM auth_user_md5 AS u
- INNER JOIN aliases AS a ON u.user_id = a.id
- INNER JOIN photo AS p ON p.uid = u.user_id
- WHERE a.alias = {?}", $m);
- if ($tmp = $res->fetchOneAssoc()) {
- $membres[$tmp['nom']] = $tmp;
- } else {
- $total--;
- }
- }
- uasort($membres, array($this, 'compare'));
- return array($total, $membres);
- }
-
- function handler_trombi(&$page, $liste = null)