Loading modules/filter/filter.module +1 −1 Original line number Diff line number Diff line Loading @@ -1704,7 +1704,7 @@ function _filter_autop($text) { // to avoid messing up code. We look for matched pairs and allow basic // nesting. For example: // "processed <pre> ignored <script> ignored </script> ignored </pre> processed" $chunks = preg_split('@(<!--.*?-->|</?(?:pre|script|style|object|iframe|!--)[^>]*>)@i', $text, -1, PREG_SPLIT_DELIM_CAPTURE); $chunks = preg_split('@(<!--.*?-->|</?(?:pre|script|style|object|iframe|svg|!--)[^>]*>)@i', $text, -1, PREG_SPLIT_DELIM_CAPTURE); // Note: PHP ensures the array consists of alternating delimiters and literals // and begins and ends with a literal (inserting NULL as required). $ignore = FALSE; Loading modules/filter/filter.test +2 −0 Original line number Diff line number Diff line Loading @@ -919,12 +919,14 @@ class FilterUnitTestCase extends DrupalUnitTestCase { <pre>aaa\nbbb\n\nccc</pre> <object>aaa\nbbb\n\nccc</object> <iframe>aaa\nbbb\n\nccc</iframe> <svg>aaa\nbbb\n\nccc</svg> " => array( "<script>aaa\nbbb\n\nccc</script>" => TRUE, "<style>aaa\nbbb\n\nccc</style>" => TRUE, "<pre>aaa\nbbb\n\nccc</pre>" => TRUE, "<object>aaa\nbbb\n\nccc</object>" => TRUE, "<iframe>aaa\nbbb\n\nccc</iframe>" => TRUE, "<svg>aaa\nbbb\n\nccc</svg>" => TRUE, ), // Skip comments entirely. "One. <!-- comment --> Two.\n<!--\nThree.\n-->\n" => array( Loading Loading
modules/filter/filter.module +1 −1 Original line number Diff line number Diff line Loading @@ -1704,7 +1704,7 @@ function _filter_autop($text) { // to avoid messing up code. We look for matched pairs and allow basic // nesting. For example: // "processed <pre> ignored <script> ignored </script> ignored </pre> processed" $chunks = preg_split('@(<!--.*?-->|</?(?:pre|script|style|object|iframe|!--)[^>]*>)@i', $text, -1, PREG_SPLIT_DELIM_CAPTURE); $chunks = preg_split('@(<!--.*?-->|</?(?:pre|script|style|object|iframe|svg|!--)[^>]*>)@i', $text, -1, PREG_SPLIT_DELIM_CAPTURE); // Note: PHP ensures the array consists of alternating delimiters and literals // and begins and ends with a literal (inserting NULL as required). $ignore = FALSE; Loading
modules/filter/filter.test +2 −0 Original line number Diff line number Diff line Loading @@ -919,12 +919,14 @@ class FilterUnitTestCase extends DrupalUnitTestCase { <pre>aaa\nbbb\n\nccc</pre> <object>aaa\nbbb\n\nccc</object> <iframe>aaa\nbbb\n\nccc</iframe> <svg>aaa\nbbb\n\nccc</svg> " => array( "<script>aaa\nbbb\n\nccc</script>" => TRUE, "<style>aaa\nbbb\n\nccc</style>" => TRUE, "<pre>aaa\nbbb\n\nccc</pre>" => TRUE, "<object>aaa\nbbb\n\nccc</object>" => TRUE, "<iframe>aaa\nbbb\n\nccc</iframe>" => TRUE, "<svg>aaa\nbbb\n\nccc</svg>" => TRUE, ), // Skip comments entirely. "One. <!-- comment --> Two.\n<!--\nThree.\n-->\n" => array( Loading