blob: 523436c69e4e9a94a891ad9396184e7ccef216d7 (
plain)
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
|
<?php
/**
* Returns room id array
*/
function Room_ids() {
$room_source = sql_select("SELECT `RID` FROM `Room` WHERE `show` = 'Y'");
if ($room_source === false)
return false;
if (count($room_source) > 0)
return $room_source;
return null;
}
/**
* Returns room by id.
*
* @param $id RID
*/
function Room($id) {
$room_source = sql_select("SELECT * FROM `Room` WHERE `RID`='" . sql_escape($id) . "' AND `show` = 'Y' LIMIT 1");
if ($room_source === false)
return false;
if (count($room_source) > 0)
return $room_source[0];
return null;
}
?>
|