diff --git a/htdocs/core/class/doleditor.class.php b/htdocs/core/class/doleditor.class.php index ff2012a5513..55474850b8e 100644 --- a/htdocs/core/class/doleditor.class.php +++ b/htdocs/core/class/doleditor.class.php @@ -88,7 +88,7 @@ class DolEditor // Define some properties if (in_array($this->tool, array('textarea', 'ckeditor', 'ace'))) { - if (! dol_textishtml($content) && $this->tool != 'textarea') { // We force content into HTML if we are using an advanced editor if content is not HTML. + if ($this->tool == 'ckeditor' && ! dol_textishtml($content)) { // We force content to be into HTML if we are using an advanced editor if content is not HTML. $this->content = dol_nl2br($content); } else { diff --git a/htdocs/modulebuilder/index.php b/htdocs/modulebuilder/index.php index d813c3b291b..5b53de530bd 100644 --- a/htdocs/modulebuilder/index.php +++ b/htdocs/modulebuilder/index.php @@ -2005,9 +2005,7 @@ elseif (!empty($module)) } dol_fiche_end(); - } - else - { + } else { // Edit text file $fullpathoffile = dol_buildpath($file, 0, 1); // Description - level 2 if ($fullpathoffile)