diff options
author | Christian Pointner <equinox@spreadspace.org> | 2012-10-26 15:03:40 +0200 |
---|---|---|
committer | Christian Pointner <equinox@spreadspace.org> | 2012-10-26 15:03:40 +0200 |
commit | 50dbc53f8625d88908aded35222383ecd67b4dbf (patch) | |
tree | fa1d077d605e2ea664fb8481e0a84c5c284903da | |
parent | runit create script with lower (diff) |
www has now lower as well
-rw-r--r-- | contrib/www/2012/embed-orf.php | 21 | ||||
-rw-r--r-- | contrib/www/2012/embed-test-orf.html | 14 | ||||
-rw-r--r-- | contrib/www/2012/init.php | 14 | ||||
-rw-r--r-- | contrib/www/2012/player.php | 40 | ||||
-rw-r--r-- | contrib/www/2012/style.css | 2 |
5 files changed, 82 insertions, 9 deletions
diff --git a/contrib/www/2012/embed-orf.php b/contrib/www/2012/embed-orf.php new file mode 100644 index 0000000..168b53f --- /dev/null +++ b/contrib/www/2012/embed-orf.php @@ -0,0 +1,21 @@ +<!DOCTYPE HTML> +<html> +<head> + <title>Elevate Festival 2012 - Live Stream</title> + <link rel="stylesheet" type="text/css" href="style.css"> + <style> + body { + margin: 0; + padding: 0; + }; + </style> +</head> +<body> + <center> +<?php +$EMBED=3; +require_once('player.php'); +?> + </center> +</body> +</html> diff --git a/contrib/www/2012/embed-test-orf.html b/contrib/www/2012/embed-test-orf.html new file mode 100644 index 0000000..6608979 --- /dev/null +++ b/contrib/www/2012/embed-test-orf.html @@ -0,0 +1,14 @@ +<!DOCTYPE HTML> +<html> +<head> + <title>Elevate Festival 2012 - Live Stream</title> + <link rel="stylesheet" type="text/css" href="style.css"> +</head> +<body> + <h1>Elevate Festival 2012 - Live Stream (embedded, orf)</h1> + <center> + <iframe src="embed-orf.php" width="440px" height="500px" frameborder=0 padding=0 margin=0> + </iframe> + </center> +</body> +</html> diff --git a/contrib/www/2012/init.php b/contrib/www/2012/init.php index 4afba69..e6f2318 100644 --- a/contrib/www/2012/init.php +++ b/contrib/www/2012/init.php @@ -11,7 +11,9 @@ if (($browser['name'] == 'firefox' && $browser['majorver'] >= 4) || $DEFAULT_MODE = 'html5'; } -if ( isset($EMBED) && $EMBED >= 2 ) { +if ( isset($EMBED) && $EMBED >= 3 ) { + $DEFAULT_PROFILE = 'lower'; +} elseif ( isset($EMBED) && $EMBED >= 2 ) { $DEFAULT_PROFILE = 'low'; } else { $DEFAULT_PROFILE = 'medium'; @@ -21,6 +23,7 @@ $PROFILE= isset($_GET['profile']) ? $_GET['profile'] : $DEFAULT_PROFILE; switch($PROFILE) { case 'high': { $WIDTH = 1280; $HEIGHT = 720; break; } case 'low': { $WIDTH = 640; $HEIGHT = 360; break; } + case 'lower': { $WIDTH = 426; $HEIGHT = 240; break; } default: { $PROFILE = 'medium'; $WIDTH = 854; $HEIGHT = 480; break; } } @@ -37,7 +40,7 @@ switch($MODE) { } $URL_BASE = 'http://' . $_SERVER['HTTP_HOST'] . $_SERVER['PHP_SELF']; -$URL_BASE_IDX = str_replace("embed.php", "index.php", $URL_BASE); +$URL_BASE_IDX = preg_replace("/embed(-.*)?\.php/", "index.php", $URL_BASE); $URL_FLASH = $URL_BASE . "?mode=flash&src=$SRC&profile=$PROFILE"; $URL_HTML5 = $URL_BASE . "?mode=html5&src=$SRC&profile=$PROFILE"; @@ -55,7 +58,12 @@ if ( isset($EMBED) && $EMBED >= 2 ) { } else { $URL_MEDIUM = $URL_BASE . "?mode=$MODE&src=$SRC&profile=medium"; } -$URL_LOW = $URL_BASE . "?mode=$MODE&src=$SRC&profile=low"; +if ( isset($EMBED) && $EMBED >= 3 ) { + $URL_LOW = $URL_BASE_IDX . "?mode=$MODE&src=$SRC&profile=low"; +} else { + $URL_LOW = $URL_BASE . "?mode=$MODE&src=$SRC&profile=low"; +} +$URL_LOWER = $URL_BASE . "?mode=$MODE&src=$SRC&profile=lower"; $STREAM_URL_BASE = 'http://elevate-live.spreadspace.org'; diff --git a/contrib/www/2012/player.php b/contrib/www/2012/player.php index cb9edba..0e4e390 100644 --- a/contrib/www/2012/player.php +++ b/contrib/www/2012/player.php @@ -1,7 +1,7 @@ <?php require_once('init.php'); ?> <table id="header" width="<?php printf('%dpx', $WIDTH); ?>"> <tr> - <td align='left' width='33%'> + <td align='left' width='23%'> <?php switch ($LANG) { case 'orig': { @@ -17,7 +17,7 @@ } ?> </td> - <td align='center' width='33%'> + <td align='center' width='30%'> <?php switch($MODE) { case 'html5': { @@ -33,7 +33,7 @@ } ?> </td> - <td align='right' width='33%'> + <td align='right' width='47%'> <?php switch($PROFILE) { case 'high': { @@ -43,7 +43,12 @@ } else { echo " <span><a href='$URL_MEDIUM'>medium</a></span>"; } - echo " <span><a href='$URL_LOW'>low</a></span>"; + if ( isset($EMBED) && $EMBED >= 3 ) { + echo " <span><a href='$URL_LOW' target='_parent'>low</a></span>"; + } else { + echo " <span><a href='$URL_LOW'>low</a></span>"; + } + echo " <span><a href='$URL_LOWER'>lower</a></span>"; break; } case 'medium': { @@ -53,7 +58,12 @@ echo " <span><a href='$URL_HIGH'>high</a></span>"; } echo " <span class='selected'>medium</span>"; - echo " <span><a href='$URL_LOW'>low</a></span>"; + if ( isset($EMBED) && $EMBED >= 3 ) { + echo " <span><a href='$URL_LOW' target='_parent'>low</a></span>"; + } else { + echo " <span><a href='$URL_LOW'>low</a></span>"; + } + echo " <span><a href='$URL_LOWER'>lower</a></span>"; break; } case 'low': { @@ -68,6 +78,26 @@ echo " <span><a href='$URL_MEDIUM'>medium</a></span>"; } echo " <span class='selected'>low</span>"; + echo " <span><a href='$URL_LOWER'>lower</a></span>"; + break; + } + case 'lower': { + if ( isset($EMBED) ) { + echo " <span><a href='$URL_HIGH' target='_parent'>high</a></span>"; + } else { + echo " <span><a href='$URL_HIGH'>high</a></span>"; + } + if ( isset($EMBED) && $EMBED >= 2 ) { + echo " <span><a href='$URL_MEDIUM' target='_parent'>medium</a></span>"; + } else { + echo " <span><a href='$URL_MEDIUM'>medium</a></span>"; + } + if ( isset($EMBED) && $EMBED >= 3 ) { + echo " <span><a href='$URL_LOW' target='_parent'>low</a></span>"; + } else { + echo " <span><a href='$URL_LOW'>low</a></span>"; + } + echo " <span class='selected'>lower</span>"; break; } } diff --git a/contrib/www/2012/style.css b/contrib/www/2012/style.css index 987d9bd..bc8919a 100644 --- a/contrib/www/2012/style.css +++ b/contrib/www/2012/style.css @@ -24,7 +24,7 @@ table#header } td { - padding: 0.5em 1em; + padding: 0.5em 0.7em; } td span { |