Parašė Kelmas· 2008 Gru. 9 18:12:21
#30
openside($locale['010']);
$result = dbquery(
"SELECT ton.*, tu.user_id,user_name,user_avatar FROM ".$db_prefix."online ton
LEFT JOIN ".$db_prefix."users tu ON ton.online_user=tu.user_id"
);
$guests = 0; $members = array();
while ($data = dbarray($result)) {
if ($data['online_user'] == "0") {
$guests++;
} else {
array_push($members, array($data['user_id'], $data['user_name']));
}
}
if (count($members) > 0) {
$i = 1;
echo "";
while (list($key, $member) = each($members)) {
echo "<a href='".BASEDIR."profile.php?lookup=".$member[0]."' class='side'>".$member[1]."
</a> |<a href='".BASEDIR."messages.php?msg_send=".$member[0]."' class='side'>Siųsti PM</a><br>";
if ($userdata['user_avatar'] != "" && file_exists(IMAGES."avatars/".$userdata['user_avatar'])) {
echo "<a href='".BASEDIR."profile.php?lookup=".$userdata['user_id']."'><img src='".IMAGES."avatars/".$userdata['user_avatar']."'></a>";
} else {
echo "<a href='".BASEDIR."profile.php?lookup=".$userdata['user_id']."'><img src='".THEME."images/KURSTOVINOAVATAR.GIF'></a>";
}
$i++;
}
echo "<br>\n";
} else {
echo $locale['013']."<br>\n";
}
closeside();
Turi veikt man atrodo.. nesigilinau iš atminties rašiau..
Redagavo Kelmas· 2008 Gru. 9 18:12:06