From 0ab0819abcc79149b831d54317c036c458968265 Mon Sep 17 00:00:00 2001 From: Pierre Rudloff Date: Sun, 10 Apr 2016 19:49:44 +0200 Subject: [PATCH] Get only scheme part of URL --- controllers/FrontController.php | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/controllers/FrontController.php b/controllers/FrontController.php index 06c8c49..cd9c2c7 100644 --- a/controllers/FrontController.php +++ b/controllers/FrontController.php @@ -123,8 +123,7 @@ class FrontController 'user_agent', $video->http_headers->{'User-Agent'} ); - $url_info = parse_url($video->url); - if ($url_info['scheme'] == 'rtmp') { + if (parse_url($video->url, PHP_URL_SCHEME) == 'rtmp') { ob_end_flush(); header( 'Content-Disposition: attachment; filename="'.