From 00823c90d64520da2e3776678e8fc2d8c500d6bd Mon Sep 17 00:00:00 2001 From: Frederic Guillot Date: Mon, 22 Jul 2013 20:23:57 -0400 Subject: [PATCH] Add support for HTML5 video inside feeds --- assets/css/app.css | 3 ++- index.php | 1 + vendor/PicoFeed/Filter.php | 2 ++ 3 files changed, 5 insertions(+), 1 deletion(-) diff --git a/assets/css/app.css b/assets/css/app.css index 906d735..9ff16bf 100644 --- a/assets/css/app.css +++ b/assets/css/app.css @@ -596,7 +596,8 @@ section li { font-size: 0.85em; } + video, iframe { - max-width: 95%; + max-width: 98%; } } diff --git a/index.php b/index.php index 429c9ac..628bb07 100644 --- a/index.php +++ b/index.php @@ -33,6 +33,7 @@ Router\before(function($action) { // HTTP secure headers Response\csp(array( + 'media-src' => '*', 'img-src' => '*', 'frame-src' => implode(' ', array( 'http://www.youtube.com', diff --git a/vendor/PicoFeed/Filter.php b/vendor/PicoFeed/Filter.php index 963ec6d..5640c20 100644 --- a/vendor/PicoFeed/Filter.php +++ b/vendor/PicoFeed/Filter.php @@ -11,6 +11,8 @@ class Filter private $strip_content = false; public $allowed_tags = array( + 'video' => array('poster', 'controls', 'height', 'width', 'src'), + 'source' => array('src', 'type'), 'dt' => array(), 'dd' => array(), 'dl' => array(),