diff options
Diffstat (limited to 'pages')
-rw-r--r-- | pages/404.php | 9 | ||||
-rw-r--r-- | pages/about.php | 8 | ||||
-rw-r--r-- | pages/feedback.php | 43 | ||||
-rw-r--r-- | pages/overview.php | 8 | ||||
-rw-r--r-- | pages/party.php | 15 | ||||
-rw-r--r-- | pages/program-json.php | 6 | ||||
-rw-r--r-- | pages/relive-player.php | 18 | ||||
-rw-r--r-- | pages/relive.php | 9 | ||||
-rw-r--r-- | pages/room.php | 124 |
9 files changed, 0 insertions, 240 deletions
diff --git a/pages/404.php b/pages/404.php deleted file mode 100644 index 0e84e5f..0000000 --- a/pages/404.php +++ /dev/null @@ -1,9 +0,0 @@ -<?php - -require_once('lib/bootstrap.php'); - -header("HTTP/1.1 404 Not Found"); -echo $tpl->render(array( - 'page' => '404', - 'title' => '404 Not Found', -)); diff --git a/pages/about.php b/pages/about.php deleted file mode 100644 index 9586e73..0000000 --- a/pages/about.php +++ /dev/null @@ -1,8 +0,0 @@ -<?php - -require_once('lib/bootstrap.php'); - -echo $tpl->render(array( - 'page' => 'about', - 'title' => 'About the Streams', -)); diff --git a/pages/feedback.php b/pages/feedback.php deleted file mode 100644 index 8b87b01..0000000 --- a/pages/feedback.php +++ /dev/null @@ -1,43 +0,0 @@ -<?php - -require_once('lib/bootstrap.php'); - -if( - !isset($_POST['datetime']) || - !isset($_POST['net']) || - !isset($_POST['os']) || - !isset($_POST['player']) || - !isset($_POST['stream']) || - !isset($_POST['provider']) || - !isset($_POST['issuetext']) -) { - echo $tpl->render(array( - 'page' => 'feedback', - 'title' => 'Give Feedback', - 'room' => null, - )); -} -else -{ - $db = new PDO(get('FEEDBACK.DSN')); - $db->setAttribute(PDO::ATTR_ERRMODE, PDO::ERRMODE_EXCEPTION); - - $stm = $db->prepare(' - INSERT INTO feedback (reported, datetime, net, os, player, stream, ipproto_v4, ipproto_v6, provider, issues, issuetext) - VALUES (:reported, :datetime, :net, :os, :player, :stream, :ipproto_v4, :ipproto_v6, :provider, :issues, :issuetext) - '); - - $stm->execute(array( - 'reported' => time(), - 'datetime' => strtotime($_POST['datetime']), - 'net' => $_POST['net'], - 'os' => $_POST['os'], - 'player' => $_POST['player'], - 'stream' => $_POST['stream'], - 'ipproto_v4' => isset($_POST['ipproto']) && is_array($_POST['ipproto']) && in_array('v4', $_POST['ipproto']), - 'ipproto_v6' => isset($_POST['ipproto']) && is_array($_POST['ipproto']) && in_array('v6', $_POST['ipproto']), - 'provider' => $_POST['provider'], - 'issues' => isset($_POST['issues']) && is_array($_POST['issues']) ? implode(',', $_POST['issues']) : '', - 'issuetext' => $_POST['issuetext'], - )); -} diff --git a/pages/overview.php b/pages/overview.php deleted file mode 100644 index 0b4434d..0000000 --- a/pages/overview.php +++ /dev/null @@ -1,8 +0,0 @@ -<?php - -require_once('lib/bootstrap.php'); - -echo $tpl->render(array( - 'page' => 'overview', - 'title' => 'Live-Streams', -)); diff --git a/pages/party.php b/pages/party.php deleted file mode 100644 index a095df3..0000000 --- a/pages/party.php +++ /dev/null @@ -1,15 +0,0 @@ -<?php - -require_once('lib/bootstrap.php'); - -$room = $_GET['room']; -echo $tpl->render(array( - 'page' => 'party', - - 'title' => $GLOBALS['CONFIG']['ROOMS'][$room], - - 'rooms' => $GLOBALS['CONFIG']['ROOMS'], - - 'room' => $room, - 'roomname' => $GLOBALS['CONFIG']['ROOMS'][$room], -)); diff --git a/pages/program-json.php b/pages/program-json.php deleted file mode 100644 index 2b5e38b..0000000 --- a/pages/program-json.php +++ /dev/null @@ -1,6 +0,0 @@ -<?php - -require_once('lib/bootstrap.php'); - -header('Content-Type: application/json'); -echo json_encode(program()); diff --git a/pages/relive-player.php b/pages/relive-player.php deleted file mode 100644 index 84fc866..0000000 --- a/pages/relive-player.php +++ /dev/null @@ -1,18 +0,0 @@ -<?php - -require_once('lib/bootstrap.php'); - -$talks_by_id = relive_talks(); -$talk = @$talks_by_id[intval($_GET['id'])]; - -if(!$talk) - return include('page/404.php'); - -echo $tpl->render(array( - 'page' => 'relive-player', - 'title' => 'Relive!', - 'talk' => $talk, - - 'width' => 1024, - 'height' => 576, -)); diff --git a/pages/relive.php b/pages/relive.php deleted file mode 100644 index 33e0d5a..0000000 --- a/pages/relive.php +++ /dev/null @@ -1,9 +0,0 @@ -<?php - -require_once('lib/bootstrap.php'); - -echo $tpl->render(array( - 'page' => 'relive', - 'title' => 'Relive!', - 'talks' => relive_talks(), -)); diff --git a/pages/room.php b/pages/room.php deleted file mode 100644 index 77f4fdf..0000000 --- a/pages/room.php +++ /dev/null @@ -1,124 +0,0 @@ -<?php - -require_once('lib/bootstrap.php'); - - -$room = $_GET['room']; -$language = $_GET['language']; -$selection = $_GET['selection']; - -if(!has("ROOMS.$room")) - return include('pages/404.php'); - -$formats = get("ROOMS.$room.FORMATS"); -$has_translation = get("ROOMS.$room.TRANSLATION"); - -$protos = array(); -$selections = array(); -$tabs = array(); -$videores = array(); - -if(room_has_hd($room)) - $selections[] = $videores[] = 'hd'; - -if(room_has_sd($room)) - $selections[] = $videores[] = 'sd'; - -if(room_has_video($room)) - $tabs[] = 'video'; - - -if(room_has_audio($room)) - $selections[] = $tabs[] = 'audio'; - -if(room_has_music($room)) - $selections[] = $tabs[] = 'music'; - -if(room_has_slides($room)) - $selections[] = $tabs[] = 'slides'; - - -if(room_has_rtmp($room)) - $protos[] = 'rtmp'; - -if(room_has_webm($room)) - $protos[] = 'webm'; - -if(room_has_hls($room)) - $protos[] = 'hls'; - - - -// default page -if(!$selection) - $selection = $selections[0]; - -if(!in_array($selection, $selections)) - return include('pages/404.php'); - - - -switch($selection) { - case 'audio': - $tab = 'audio'; - $title = 'Audio'; - break; - - case 'music': - $tab = 'music'; - $title = 'Music'; - break; - - case 'slides': - $tab = 'slides'; - $title = 'Slides'; - $width = 1024; - $height = 576; - break; - - case 'hd': - $tab = 'video'; - $title = 'FullHD Video'; - $width = 1920; - $height = 1080; - break; - - case 'sd': - $tab = 'video'; - $title = 'SD Video'; - $width = 1024; - $height = 576; - break; -} - -if($language == 'translated') -{ - if(!$has_translation) - return include('pages/404.php'); - - $title = 'Translated '.$title; -} - -echo $tpl->render(array( - 'page' => 'room', - - 'title' => get("ROOMS.$room.DISPLAY").' – '.$title, - 'room' => $room, - - 'program' => program(), - - 'tab' => $tab, - 'tabs' => $tabs, - - 'width' => @$width, - 'height' => @$height, - 'language' => $language, - 'translated' => ($language == 'translated'), - 'selection' => $selection, - 'hlsformat' => ($selection == 'hd' ? 'auto' : $selection), - - 'has_translation' => $has_translation, - 'formats' => $formats, - 'protos' => $protos, - 'videores' => $videores, -)); |