From b525810c14a5602f11949a40529f6a809c29b679 Mon Sep 17 00:00:00 2001 From: Dennis Verspuij Date: Mon, 19 Mar 2018 10:01:20 +0000 Subject: [PATCH] Fix removal of on=... attributes from html generated from markdown --- plugins/markdown/markdown.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/plugins/markdown/markdown.php b/plugins/markdown/markdown.php index 6b4aabf3..2f24e417 100644 --- a/plugins/markdown/markdown.php +++ b/plugins/markdown/markdown.php @@ -288,7 +288,7 @@ function ($match) { return escape($match[0]); }, $description); } $description = preg_replace( - '#(<[^>]+)on[a-z]*="?[^ "]*"?#is', + '#(<[^>]+\s)on[a-z]*="?[^ "]*"?#is', '$1', $description); return $description;