]> git.koha-community.org Git - koha.git/commit
Bug 27422: YouTube videos are HTTPS only
authorTomas Cohen Arazi <tomascohen@theke.io>
Wed, 3 Feb 2021 22:50:29 +0000 (19:50 -0300)
committerFridolin Somers <fridolin.somers@biblibre.com>
Fri, 12 Feb 2021 14:27:50 +0000 (15:27 +0100)
commited2765ddc38c7c19461806b996319aed147c188f
treedc05ffdbefa64ffc92d16263fbaec4e70ba2c447
parent37c938784733dd8e80fe0d480ffe734c4272e9f0
Bug 27422: YouTube videos are HTTPS only

This patch hardcodes HTTPS as the protocol to use when generating
YouTube content embedding. It is the supported protocol and without this
patch it falls back to 'http', or it can be 'ftp' depending on the first
indicator of the 856 field. They are all not supported so hardcoding it.

To test:
1. Have a record with 856 $uhttps://youtu.be/sMNkDPFycNU
2. Enable the HTML5MediaYouTube and HTML5Media sysprefs
3. Open the OPAC detailed view of the record
4. Open the Multimedia tab
=> FAIL: There's no embedded video
5. Apply this patch
6. Restart all
7. Repeat 4
=> SUCCESS: There's a live performance of Heroes del Silencio!
8. Sign off :-D

Sponsored-by: Banco Central de la República Argentina
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Signed-off-by: David Cook <dcook@prosentient.com.au>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
(cherry picked from commit ca5efc9aa45c3c7893a09cf0067718fdaab63507)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
C4/HTML5Media.pm