aragonc 9 жил өмнө
parent
commit
d3e6986fe5

+ 1 - 1
main/inc/lib/formvalidator/FormValidator.class.php

@@ -753,7 +753,7 @@ EOT;
     {
         $config['rows'] = isset($config['rows']) ? $config['rows'] : 15;
         $config['cols'] = isset($config['cols']) ? $config['cols'] : 80;
-        $this->addElement('html_editor', $name, $label, $config);
+        $this->addElement('html_editor', $name, $label, $config, $style);
         $this->applyFilter($name, 'trim');
         if ($required) {
             $this->addRule($name, get_lang('ThisFieldIsRequired'), 'required');

+ 4 - 3
main/newscorm/learnpath.class.php

@@ -7592,9 +7592,10 @@ class learnpath
 
                         $form->addButtonSave($text, 'submit_button');
                         $renderer = $form->defaultRenderer();
-                        $renderer->setElementTemplate('<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;{label}<br />{element}', 'content_lp');
-                        $form->addElement('html', '<div>');
-                        $form->addElement('html_editor', 'content_lp', '', null, $editor_config);
+                        $renderer->setElementTemplate('&nbsp;{label}{element}', 'content_lp');
+                        $form->addElement('html', '<div class="editor-lp">');
+                        $form->addHtmlEditor('content_lp', null, null, true, $editor_config, $style=true);
+                        //$form->addElement('html_editor', 'content_lp', '', null, $editor_config);
                         $form->addElement('html', '</div>');
                         $defaults['content_lp'] = $content;
                     }