forked from leftypol/leftypol
Prevent double-encoding of HTML entities in [code]
This commit is contained in:
parent
b792bd7b07
commit
e418f1e3aa
1 changed files with 2 additions and 2 deletions
|
@ -2196,8 +2196,8 @@ function markup(&$body, $track_cites = false, $op = false) {
|
|||
|
||||
$code = rtrim(ltrim($code, "\r\n"));
|
||||
|
||||
$code = "<pre class='code lang-$code_lang'>".str_replace(array("\n","\t"), array(" ","	"), htmlspecialchars($code))."</pre>";
|
||||
|
||||
$code = "<pre class='code lang-$code_lang'>".str_replace(array("\n","\t"), array(" ","	"), htmlspecialchars($code, ENT_COMPAT, "UTF-8", false))."</pre>";
|
||||
|
||||
$body = str_replace("<code $id>", $code, $body);
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue