Markdown: Protecting some more BBCode elements

pull/932/head
Michael 2019-12-30 02:25:01 +00:00
parent c03588f0b4
commit d0a7623b94
1 changed files with 2 additions and 1 deletions

View File

@ -50,7 +50,8 @@ function markdown_post_local_start(App $a, &$request) {
}
// Elements that shouldn't be parsed
$elements = ['code', 'noparse', 'nobb', 'pre', 'share', 'url', 'img'];
$elements = ['code', 'noparse', 'nobb', 'pre', 'share', 'url', 'img', 'bookmark',
'audio', 'video', 'youtube', 'vimeo', 'attachment', 'iframe', 'map', 'mail'];
foreach ($elements as $element) {
$request['body'] = preg_replace_callback("/\[" . $element . "(.*?)\](.*?)\[\/" . $element . "\]/ism",
function ($match) use ($element) {