From 04f7bcfa68903b097a4ed2cc36d67f20f1c6bb0d Mon Sep 17 00:00:00 2001 From: Yohann Date: Sun, 22 Dec 2019 19:10:30 +0100 Subject: [PATCH] =?UTF-8?q?Correction=20d'un=20probl=C3=A8me=20concernant?= =?UTF-8?q?=20l'affichage=20des=20vid=C3=A9os=20Youtube?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- server_files/model.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/server_files/model.php b/server_files/model.php index bdcab22..bf48200 100644 --- a/server_files/model.php +++ b/server_files/model.php @@ -298,7 +298,7 @@ function exportProblemsData() { function displayVideo($link) { - if (preg_match("#(https?://|)(www\.|)(youtube\.com/watch\?v=|youtu.be/)(.*)#", $link, $matches)) { + if (preg_match("#(https?://|)(www\.|)(youtube\.com/watch\?v=|youtu.be/)([a-zA-Z0-9]*)?.*?#", $link, $matches)) { $code = $matches[4]; /** @noinspection HtmlDeprecatedAttribute */ /** @noinspection HtmlDeprecatedTag */