diff --git a/etemplate/inc/class.etemplate_old.inc.php b/etemplate/inc/class.etemplate_old.inc.php index eaba35b7b2..85273b20c1 100644 --- a/etemplate/inc/class.etemplate_old.inc.php +++ b/etemplate/inc/class.etemplate_old.inc.php @@ -1348,6 +1348,7 @@ class etemplate_old extends boetemplate self::$request->set_to_process($form_name,$cell['type'],array( 'needed' => $cell['needed'], + 'mode' => $mode, // need mode to not run purify for $mode=='ascii' )); } else @@ -2228,8 +2229,12 @@ class etemplate_old extends boetemplate } break; case 'htmlarea': - self::set_array($content,$form_name,html::purify($value)); - break; + if ($attr['mode'] !== 'ascii') + { + self::set_array($content,$form_name,html::purify($value)); + break; + } + // fall-throught for mode 'ascii', which is identical to textarea case 'int': case 'float': case 'passwd':