Removing overriden method for fencedCodeBlocks.

Michel Fortin's implementation is able to handle the fencedCodeBlock without any escaping mecanism.
This commit is contained in:
Michiel Missotten 2014-02-14 10:06:15 +01:00
parent 7c05b45fae
commit a9bca9ffc6

View file

@ -265,17 +265,4 @@ class MarkdownParser extends MarkdownExtra implements MarkdownParserInterface
#
return $this->hashPart("<code>$code</code>");
}
public function _doFencedCodeBlocks_callback($matches)
{
$codeblock = $matches[2];
if (!$this->features['no_html']) {
$codeblock = htmlspecialchars($codeblock, ENT_NOQUOTES);
}
$codeblock = preg_replace_callback('/^\n+/',
array(&$this, '_doFencedCodeBlocks_newlines'), $codeblock);
$codeblock = "<pre><code>$codeblock</code></pre>";
return "\n\n".$this->hashBlock($codeblock)."\n\n";
}
}