Ok ich will nur das bester "CMS Der Welt" haben ob das ne Community nutzt ist mir egal ^^
Aber morgen kommt das dann ^^
mfg
SLJ
Hier kann eine Notiz zum Merk-Eintrag hinzugefügt werden (optional)
Geschlossen |
<?php //Copyright by Hannes Wunderli //www.fast-death.com // v1.2b defined ('main') or die ( 'no direct access' ); //----------------------------------- Einstellungen----------------------------------- $recht = -1; //Anzeige Modus 0 = Alle / -1 Alle die mehr als Memberrechte haben usw. $showavatars = 1; //Wenn 1 werden die Avatare wenn vorhanden angezeigt. //------------------------------------------------------------------------------------ $timestamp = time(); $akttime = date('Y-m-d',$timestamp); function get_gebtage ($datum) { list($y, $m, $d) = explode('-', $datum); return ($d.'.'.$m.'.'.$y); } # DIE krasse Abfrage :-)... von Manuel $q = "SELECT name, id, avatar, CASE WHEN ( MONTH(gebdatum) < MONTH(NOW()) ) OR ( MONTH(gebdatum) <= MONTH(NOW()) AND DAYOFMONTH(gebdatum) < DAYOFMONTH(NOW()) ) THEN gebdatum + INTERVAL (YEAR(NOW()) - YEAR(gebdatum) + 1) YEAR ELSE gebdatum + INTERVAL (YEAR(NOW()) - YEAR(gebdatum)) YEAR END AS gebtage FROM prefix_user WHERE gebdatum > 0000-00-00 AND recht <= ".$recht." ORDER BY gebtage"; $erg = db_query($q); echo '<table width="100%" cellspacing="0" cellpadding="0">'; while($row = db_fetch_object($erg)) { if($akttime == $row->gebtage) { echo '<tr><td align="center">'.$lang['today'].' '.$lang['had'].' <a class="box" href="index.php?user-details-'.$row->id.'">'.$row->name.'</a><br / >'.$lang['birthday'].'<br / >'; if ($showavatars && $row->avatar) { echo '<br /><img border="0" src="'.$row->avatar.'">'; } else { echo'<img border="0" src="include/images/icons/birthday.gif">'; echo "</td></tr>"; } } } echo '<tr><td> </td></tr>'; echo '</table>'; ?>
if ($row->uid == 0) { $guests++; } $brk=$row->uid; } if ($guests == 1) { $guestn = $lang['guest']; } if (empty($content)) { $content.='<tr><td><img src="include/images/icons/offline.gif" border="0" alt="offline"></td><td><font color="#003366">0 User </font></td><tr>'."\n"; } $content.='<tr><td colspan="2"><hr style="height: 0px; border: dashed #9AB1C8 0px; border-top-width: 1px;"></td></tr>'."\n"; $where = (count($uid)>0) ? 'WHERE id NOT IN ('.implode(', ', $uid).')' : ''; $abf2 = 'SELECT * FROM prefix_user '.$where.' ORDER BY llogin DESC LIMIT 0,5'; $erg2 = db_query($abf2); while ($row2 = db_fetch_object($erg2)) { $datum = date('H:i d.m.y',$row2->llogin); $user = $row2->name; $abf2 = db_query("SELECT id,name, geschlecht, gebdatum FROM prefix_user WHERE id= '".$row2->id."' "); $row0 = db_fetch_object($abf2); $geb = $row2->gebdatum; $a = explode('-', $geb); $endung = $a[count($a) - 1]; $tag = $a[2]; $mon = $a[1]; $jah = $a[0]; $jetzt = mktime(0,0,0,date("m"),date("d"),date("Y")); $gebur = mktime(0,0,0,$mon,$tag,$jah); $age1 = intval(($jetzt - $gebur) / (3600 * 24 * 365)); if ($row0->geschlecht == 0){ if ($row2->gebdatum != 0000-00-00 ){ $content.='<tr><td><img src="include/images/icons/offline.gif" border="0" alt="offline"></td><td><a href="index.php?user-details-'.$row2->id.'" title="'.$lang['lasttimeonline'].$datum.'">('.$age1.') '.$row0->name.'</a></td></tr>'."\n"; $uid[] = $row->uid; }else{ $content.='<tr><td><img src="include/images/icons/offline.gif" border="0" alt="offline"></td><td><a href="index.php?user-details-'.$row2->id.'" title="'.$lang['lasttimeonline'].$datum.'">'.$row0->name.'</a></td></tr>'."\n"; $uid[] = $row->uid; } } elseif ($row0->geschlecht == 1){ if ($row2->gebdatum != 0000-00-00 ){ $content.='<tr><td><img src="include/images/icons/offline.gif" border="0" alt="offline"></td><td><a href="index.php?user-details-'.$row2->id.'" title="'.$lang['lasttimeonline'].$datum.'">(M-'.$age1.') '.$row1->name.'</a></td></tr>'."\n"; $uid[] = $row->uid; }else{ $content.='<tr><td><img src="include/images/icons/offline.gif" border="0" alt="offline"></td><td><a href="index.php?user-details-'.$row2->id.'" title="'.$lang['lasttimeonline'].$datum.'">(M) '.$row1->name.'</a></td></tr>'."\n"; $uid[] = $row->uid; } } elseif ($row0->geschlecht == 2){ if ($row2->gebdatum != 0000-00-00 ){ $content.='<tr><td><img src="include/images/icons/offline.gif" border="0" alt="offline"></td><td><a href="index.php?user-details-'.$row2->id.'" title="'.$lang['lasttimeonline'].$datum.'">(W-'.$age1.') '.$row1->name.'</a></td></tr>'."\n"; $uid[] = $row->uid; }else{ $content.='<tr><td><img src="include/images/icons/offline.gif" border="0" alt="offline"></td><td><a href="index.php?user-details-'.$row2->id.'" title="'.$lang['lasttimeonline'].$datum.'">(W) '.$row1->name.'</a></td></tr>'."\n"; $uid[] = $row->uid; } }
Geschlossen | ||
Zurück zu Module und Modifikationen |