Das ist der Code der freundesliste:
<?php defined('main') or die('no direct access'); if (loggedin()) { $dif = date('Y-m-d H:i:s', time() - 60); $sql = db_query("SELECT a.fid as aktfid, b.name, IF(MAX(c.uptime) > '$dif','online','offline') as status FROM `prefix_friends` a LEFT JOIN `prefix_user` b ON a.fid = b.id LEFT JOIN `prefix_online` c ON a.fid = c.uid WHERE a.uid = {$_SESSION['authid']} GROUP BY a.fid, b.name ORDER BY status DESC"); while ($r = db_fetch_object($sql)) { echo '<img src="include/images/icons/'.$r->status.'.gif" alt="'.$r->status.'" border="0" /> <a href="index.php?forum-privmsg-new=0&empfid='.$r->aktfid.'">'.$r->name.'</a><br />'; } echo '<br /><a href="index.php?freunde">Freundeliste bearbeiten</a><br />'; } else { echo 'Nur für angemeldete User.<br />'; } ?>
Zuletzt modifiziert von naofireblade am 30.03.2010 - 10:31:06