From 63739a1a41f8a89a3b3d85ea014a54fb9e5e04bd Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Marc=20W=C3=A4ckerlin?= Date: Sat, 24 Oct 2015 09:09:26 +0000 Subject: [PATCH] rescue of raum --- src/index.php | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/src/index.php b/src/index.php index 7c1dc8f..2f150a5 100644 --- a/src/index.php +++ b/src/index.php @@ -70,9 +70,9 @@ function source($dir, $file, $mime=NULL) { if (!$mime) $type=mime_content_type($path); else $type='video/'.$mime; echo ''; + .'" type="'.$type.'">'."\n"; } else { - return ''; + echo "Not Found: $path for $mime"; } } @@ -97,7 +97,7 @@ function fileRange($path, $size, $mime) { $size)); // Total size of the file // It's time to output the file - $f = fopen($file, 'rb'); // Open the file in binary mode + $f = fopen($path, 'rb'); // Open the file in binary mode $chunkSize = 8192; // The size of each chunk to output // Seek to the requested start range @@ -124,7 +124,7 @@ function output($path) { fileRange($path, $size, $mime); } else { header('Content-Length: ' . $size); - @readfile($file); + @readfile($path); @ob_flush(); flush(); } @@ -138,6 +138,7 @@ function ext($file, $newext) { /** Show a video player for the given video */ function player($video) { + global $DIR, $CONVERT; $URL=pageUrl(); ?>