From 57511ebc15068112b41163a8708d058a8af42985 Mon Sep 17 00:00:00 2001 From: Nick Clemens Date: Tue, 23 Oct 2018 12:30:25 +0000 Subject: [PATCH] Bug 21476: Fix HTML5 media from playing in the OPAC - incorrect filters This patch makes a correction to a template filter to prevent incorrectly-encoded HTML in media source links which were preventing media from embedding correctly in the OPAC. To test, apply the patch and enable the HTML5MediaEnabled and HTML5MediaYouTube system preferences. - Edit a record to include links to videos in 856$u. For example: - https://www.youtube.com/watch?v=grTwH6Evdfc - https://archive.org/download/POPEYEMeetsSindbadTheSailor1936/POPEYE%20meets%20Sindbad%20The%20Sailor%20%281936%29.ogv View the record in the OPAC and confirm that the videos display in the "Play media" tab and that they play correctly. Tested and works as described, also matches the intranet code. Signed-off-by: Alex Buckley Signed-off-by: Jonathan Druart Signed-off-by: Nick Clemens (cherry picked from commit 7736b5c2e32975502fa6198b5f7ec64feb7b8ffc) Signed-off-by: Martin Renvoize (cherry picked from commit 18bb4d5e66f4bfc74144bce2f730359b55526b08) Signed-off-by: Fridolin Somers --- koha-tmpl/opac-tmpl/bootstrap/en/modules/opac-detail.tt | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/koha-tmpl/opac-tmpl/bootstrap/en/modules/opac-detail.tt b/koha-tmpl/opac-tmpl/bootstrap/en/modules/opac-detail.tt index e92d830beb..217c34e5a8 100644 --- a/koha-tmpl/opac-tmpl/bootstrap/en/modules/opac-detail.tt +++ b/koha-tmpl/opac-tmpl/bootstrap/en/modules/opac-detail.tt @@ -997,10 +997,10 @@ [% FOREACH HTML5MediaSet IN HTML5MediaSets %]

[% SET ctrl_preload = ' controls preload=none' #translatability %] - <[% HTML5MediaParent _ ctrl_preload %] > - <[% HTML5MediaSet.child _ ' src="' _ HTML5MediaSet.srcblock _'"' _ HTML5MediaSet.typeblock %] /> - [[% HTML5MediaParent %] tag not supported by your browser.] - + <[% HTML5MediaParent _ ctrl_preload | html %] > + <[% HTML5MediaSet.child | html %] src="[% HTML5MediaSet.srcblock | html %]" [% HTML5MediaSet.typeblock | html %] /> + [[% HTML5MediaParent | html %] tag not supported by your browser.] +

[% END %] -- 2.39.5