瀏覽代碼

Merge pull request #1103 from dennisverspuij/fix-on-in-markdown

 Fix removal of on=... attributes from html (generated from markdown)
ArthurHoaro 6 年之前
父節點
當前提交
838ef8a6ec
共有 1 個文件被更改,包括 1 次插入1 次删除
  1. 1 1
      plugins/markdown/markdown.php

+ 1 - 1
plugins/markdown/markdown.php

@@ -288,7 +288,7 @@ function sanitize_html($description)
             $description);
     }
     $description = preg_replace(
-        '#(<[^>]+)on[a-z]*="?[^ "]*"?#is',
+        '#(<[^>]+\s)on[a-z]*="?[^ "]*"?#is',
         '$1',
         $description);
     return $description;