-
Notifications
You must be signed in to change notification settings - Fork 3
/
quick-rooms.php
31 lines (23 loc) · 955 Bytes
/
quick-rooms.php
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
<?php
include "global.php";
if (!LOGGED_IN) {
header('Location: ' . WWW);
exit;
}
$result = db::query("SELECT `id`,`caption` FROM `rooms_data` WHERE `owner` = '" . USER_NAME . "'");
if ($result->rowCount() <= 0) {
echo '<ul><li>Você ainda não tem nenhuma sala!</li></ul>';
} else {
$oddeven = 'odd';
echo "<ul id='quickmenu-rooms'>";
while ($row = $result->fetch(1)) {
if ($oddeven == "even") {
$oddeven = 'odd';
} else if ($oddeven == "odd") {
$oddeven = 'even';
}
echo "<li class='" . $oddeven . "'><a href='" . WWW . '/client?forwardId=2&roomId=' . $row[0] . "' target='uberClientWnd' onclick=\"HabboClient.openOrFocus(this); return false;\">" . $row[1] . "</a></li>";
}
echo "</ul>";
}
echo "<p class='create-room'><a href='" . WWW . "/client' target='uberClientWnd' onclick=\"HabboClient.openOrFocus(this); return false;\">Crie uma nova sala</a></p>";