Code Duplication    Length = 6-6 lines in 3 locations

include/functions.php 3 locations

@@ 236-241 (lines=6) @@
233
234
    // Only for Xoops 2.0.x
235
    switch ($editor_option) {
236
        case 'fckeditor':
237
            if (is_readable(XOOPS_ROOT_PATH . '/class/fckeditor/formfckeditor.php')) {
238
                require_once(XOOPS_ROOT_PATH . '/class/fckeditor/formfckeditor.php');
239
                $editor = new XoopsFormFckeditor($caption, $name, $value);
240
            }
241
            break;
242
243
        case 'htmlarea':
244
            if (is_readable(XOOPS_ROOT_PATH . '/class/htmlarea/formhtmlarea.php')) {
@@ 243-248 (lines=6) @@
240
            }
241
            break;
242
243
        case 'htmlarea':
244
            if (is_readable(XOOPS_ROOT_PATH . '/class/htmlarea/formhtmlarea.php')) {
245
                require_once(XOOPS_ROOT_PATH . '/class/htmlarea/formhtmlarea.php');
246
                $editor = new XoopsFormHtmlarea($caption, $name, $value);
247
            }
248
            break;
249
250
        case 'dhtmltextarea':
251
        case 'dhtml':
@@ 267-272 (lines=6) @@
264
            }
265
            break;
266
267
        case 'koivi':
268
            if (is_readable(XOOPS_ROOT_PATH . '/class/wysiwyg/formwysiwygtextarea.php')) {
269
                require_once(XOOPS_ROOT_PATH . '/class/wysiwyg/formwysiwygtextarea.php');
270
                $editor = new XoopsFormWysiwygTextArea($caption, $name, $value, $width, $height, '');
271
            }
272
            break;
273
    }
274
275
    return $editor;