aboutsummaryrefslogtreecommitdiff
path: root/room.php
blob: c297610151ac207de6731358886b20f877ed67c4 (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
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
<?php

require_once('lib/bootstrap.php');

$room = $_GET['room'];
$language = $_GET['language'];
$format = $_GET['format'];

switch($format) {
	case 'audio':
		$type = 'audio';
		break;

	case 'slides':
		$type = 'slides';
		break;

	case 'hd':
		$type = 'video';
		$width = 1920;
		$height = 1080;
		break;

	case 'hq':
		$type = 'video';
		$width = 1024;
		$height = 576;
		break;

	case 'lq':
		$type = 'video';
		$width = 640;
		$height = 360;
		break;
}

echo $tpl->render(array(
	'page' => 'room',

	'title' => $GLOBALS['CONFIG']['ROOMS'][$room].' – '.$GLOBALS['CONFIG']['FORMATS'][$format],

	'rooms' => $GLOBALS['CONFIG']['ROOMS'],
	'formats' => $GLOBALS['CONFIG']['FORMATS'],

	'room' => $room,
	'roomname' => $GLOBALS['CONFIG']['ROOMS'][$room],

	'program' => program(),

	'type' => $type,
	'width' => @$width,
	'height' => @$height,
	'language' => $language,
	'translated' => ($language == 'translated'),
	'format' => $format,

	// miniroom = no hd, no translation, no slides, no irc, no program
	//   -> sendezentrum, workshops
	'miniroom' => in_array($room, array('sendezentrum')),
));