Skip to content

Commit

Permalink
Added escape sequense
Browse files Browse the repository at this point in the history
  • Loading branch information
Andrey Pozolotin committed Mar 1, 2017
1 parent 4462559 commit 5fdec87
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion library/HTMLPurifier/Filter/ExtractStyleBlocks.php
Original file line number Diff line number Diff line change
Expand Up @@ -95,7 +95,7 @@ public function preFilter($html, $config, $context)
if ($tidy !== null) {
$this->_tidy = $tidy;
}
$html = preg_replace_callback('#<style(?:\s.*)?>(.*)</style>#isU', array($this, 'styleCallback'), $html);
$html = preg_replace_callback('#<style(?:\s.*)?>(.*)<\/style>#isU', array($this, 'styleCallback'), $html);
$style_blocks = array_filter($this->_styleMatches);
$this->_styleMatches = array(); // reset
$context->register('StyleBlocks', $style_blocks); // $context must not be reused
Expand Down

0 comments on commit 5fdec87

Please sign in to comment.