在最近的 cakePHP 1.3.4 版本中,我发现 Sanitize::html 返回双重编码的 html 实体 - 因为新添加的 htmlentities 'double_encode' 的第四个参数。
这是 cakePHP 的相应票证:http: //cakephp.lighthouseapp.com/projects/42648/tickets/1152-sanitizehtml-needs-double_encode-parameter-in-htmlentities
由于我需要在 PHP 5.2.14 上使用 cakePHP 1.3.4,我需要更改 double_encode 参数。有没有办法重载蛋糕中的 Sanitize::html 方法,这样我就不必摆弄核心了?