mirror of
https://git.friendi.ca/friendica/friendica-addons.git
synced 2024-12-25 18:40:17 +00:00
Merge pull request #932 from annando/markdown-more-elements
Markdown: Protecting some more BBCode elements
This commit is contained in:
commit
14850e553a
1 changed files with 2 additions and 1 deletions
|
@ -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) {
|
||||
|
|
Loading…
Reference in a new issue