From 731978fda6a35393f11e304d94fcc21926302092 Mon Sep 17 00:00:00 2001 From: Francis Appels Date: Sun, 28 Jun 2020 16:33:44 +0200 Subject: [PATCH 1/2] FIX html lost on html extrafield --- htdocs/core/class/extrafields.class.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/htdocs/core/class/extrafields.class.php b/htdocs/core/class/extrafields.class.php index e1a834a42ca..ae5d41dba48 100644 --- a/htdocs/core/class/extrafields.class.php +++ b/htdocs/core/class/extrafields.class.php @@ -2086,7 +2086,7 @@ class ExtraFields $value_key = ''; } } - elseif (in_array($key_type, array('price', 'double'))) + elseif (in_array($key_type, array('price', 'double', 'html'))) { $value_arr = GETPOST("options_".$key, 'alpha'); $value_key = price2num($value_arr); From 5d65b5f66025473cfca99bb6bd48f0c5f7fbfc71 Mon Sep 17 00:00:00 2001 From: Francis Appels Date: Mon, 29 Jun 2020 09:07:54 +0200 Subject: [PATCH 2/2] fix html should not do price2num --- htdocs/core/class/extrafields.class.php | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/htdocs/core/class/extrafields.class.php b/htdocs/core/class/extrafields.class.php index ae5d41dba48..caf43f94342 100644 --- a/htdocs/core/class/extrafields.class.php +++ b/htdocs/core/class/extrafields.class.php @@ -2086,11 +2086,15 @@ class ExtraFields $value_key = ''; } } - elseif (in_array($key_type, array('price', 'double', 'html'))) + elseif (in_array($key_type, array('price', 'double'))) { $value_arr = GETPOST("options_".$key, 'alpha'); $value_key = price2num($value_arr); } + elseif (in_array($key_type, array('html'))) + { + $value_key = GETPOST("options_".$key, 'alpha'); + } else { $value_key = GETPOST("options_".$key);