Fixes #973 - Double encode HTML entities in CodeEditor value

This commit is contained in:
Samuel Georges 2015-02-28 10:38:04 +11:00
parent bff70a053f
commit 3524b17484
1 changed files with 3 additions and 1 deletions

View File

@ -119,7 +119,9 @@ class CodeEditor extends FormWidgetBase
$this->vars['stretch'] = $this->formField->stretch;
$this->vars['size'] = $this->formField->size;
$this->vars['name'] = $this->formField->getName();
$this->vars['value'] = $this->getLoadValue();
// Double encode when escaping
$this->vars['value'] = htmlentities($this->getLoadValue(), ENT_QUOTES, 'UTF-8', true);
}
/**