PM-1518 Campo de Texto no guarda bien datos con comilla simple

Se verifico el problema en campos de tipo hidden
This commit is contained in:
norahmollo
2015-02-09 11:46:03 -04:00
parent 21a11e0417
commit 3c77928eb3

View File

@@ -3443,11 +3443,12 @@ class XmlForm_Field_Hidden extends XmlForm_Field
} }
} }
} }
//$html .= 'value="' . $this->htmlentities( $value, ENT_QUOTES, 'utf-8' ) . '" ';
if ($this->mode === 'edit') { if ($this->mode === 'edit') {
return '<input id="form[' . $this->name . ']" ' . $this->NSFieldType() . ' name="form[' . $this->name . ']" type=\'hidden\' value=\'' . $value . '\'/>'; return '<input id="form[' . $this->name . ']" ' . $this->NSFieldType() . ' name="form[' . $this->name . ']" type=\'hidden\' value=\'' . $this->htmlentities( $value, ENT_QUOTES, 'utf-8' ) . '\'/>';
} elseif ($this->mode === 'view') { } elseif ($this->mode === 'view') {
//a button? who wants a hidden field be showed like a button?? very strange. //a button? who wants a hidden field be showed like a button?? very strange.
return '<input id="form[' . $this->name . ']" ' . $this->NSFieldType() . ' name="form[' . $this->name . ']" type=\'text\' value=\'' . $value . '\' style="display:none"/>'; return '<input id="form[' . $this->name . ']" ' . $this->NSFieldType() . ' name="form[' . $this->name . ']" type=\'text\' value=\'' . $this->htmlentities( $value, ENT_QUOTES, 'utf-8' ) . '\' style="display:none"/>';
} else { } else {
return $this->htmlentities( $value, ENT_COMPAT, 'utf-8' ); return $this->htmlentities( $value, ENT_COMPAT, 'utf-8' );
} }