Use system.allowed_oembed config to allow iframe source

This commit is contained in:
Hypolite Petovan 2021-03-14 13:41:43 -04:00
parent 93823ecef5
commit 393de1a283
2 changed files with 8 additions and 1 deletions

View file

@ -1884,6 +1884,13 @@ class BBCode
'player.vimeo.com/video/',
];
$allowedIframeDomains = array_merge(
$allowedIframeDomains,
DI::config()->get('system', 'allowed_oembed') ?
explode(',', DI::config()->get('system', 'allowed_oembed'))
: []
);
$text = HTML::purify($text, $allowedIframeDomains);
return $text;