Code Duplication    Length = 5-5 lines in 4 locations

htdocs/modules/wflinks/admin/category.php 1 location

@@ 104-108 (lines=5) @@
101
    $indeximage_select -> setExtra("onchange='showImgSelected(\"image\", \"imgurl\", \"" . $xoopsModuleConfig['catimage'] . "\", \"\", \"" . XOOPS_URL . "\")'");
102
    $indeximage_tray = new XoopsFormElementTray(_AM_WFL_FCATEGORY_CIMAGE, ' ');
103
    $indeximage_tray -> addElement($indeximage_select);
104
    if (!empty($imgurl)) {
105
        $indeximage_tray -> addElement(new XoopsFormLabel('', "<br /><br /><img src='" . XOOPS_URL . "/" . $xoopsModuleConfig['catimage'] . "/" . $imgurl . "' name='image' id='image' alt='' />"));
106
    } else {
107
        $indeximage_tray -> addElement(new XoopsFormLabel('', "<br /><br /><img src='" . XOOPS_URL . "/uploads/blank.gif' name='image' id='image' alt='' />"));
108
    }
109
    $sform -> addElement($indeximage_tray);
110
111
    $editor = wfl_getWysiwygForm( _AM_WFL_FCATEGORY_DESCRIPTION, 'description', $description, 15, 60, '');

htdocs/modules/wflinks/admin/indexpage.php 1 location

@@ 68-72 (lines=5) @@
65
        $indeximage_select -> setExtra( "onchange='showImgSelected(\"image\", \"indeximage\", \"" . $xoopsModuleConfig['mainimagedir'] . "\", \"\", \"" . XOOPS_URL . "\")'" );
66
        $indeximage_tray = new XoopsFormElementTray( _AM_WFL_IPAGE_CIMAGE, '&nbsp;' );
67
        $indeximage_tray -> addElement( $indeximage_select );
68
        if ( !empty( $indeximage ) ) {
69
            $indeximage_tray -> addElement( new XoopsFormLabel( '', "<br /><br /><img src='" . XOOPS_URL . "/" . $xoopsModuleConfig['mainimagedir'] . "/" . $indeximage . "' name='image' id='image' alt='' />" ) );
70
        } else {
71
            $indeximage_tray -> addElement( new XoopsFormLabel( '', "<br /><br /><img src='" . XOOPS_URL . "/uploads/blank.gif' name='image' id='image' alt='' />" ) );
72
        }
73
        $sform -> addElement( $indeximage_tray );
74
75
        $editor = wfl_getWysiwygForm( _AM_WFL_IPAGE_CHEADING, 'indexheader', $indexheader, 15, 60, '');

htdocs/modules/wflinks/admin/main.php 1 location

@@ 180-184 (lines=5) @@
177
    $indeximage_tray = new XoopsFormElementTray( _AM_WFL_LINK_SHOTIMAGE, '&nbsp;' );
178
    $indeximage_tray -> setDescription( sprintf( _AM_WFL_LINK_MUSTBEVALID, "<b>" . $directory . "</b>" ));
179
    $indeximage_tray -> addElement( $indeximage_select );
180
    if ( !empty( $imgurl ) ) {
181
        $indeximage_tray -> addElement( new XoopsFormLabel( '', " <br /><br />< img src='" . XOOPS_URL . "/" . $xoopsModuleConfig['screenshots'] . "/" . $screenshot . "' name = 'image' id = 'image' alt = '' / > " ) );
182
    } else {
183
        $indeximage_tray -> addElement( new XoopsFormLabel( '', " <br /><br /><img src='" . XOOPS_URL . "/uploads/blank.gif' name='image' id='image' alt='' / > " ) );
184
    }
185
    $sform -> addElement( $indeximage_tray );
186
187
if ($xoopsModuleConfig['useaddress']) {

htdocs/modules/wflinks/admin/upload.php 1 location

@@ 91-95 (lines=5) @@
88
            $indeximage_select -> setExtra( "onchange='showImgSelected(\"image\", \"linkfile\", \"" . $dirarray[$rootpath] . "\", \"\", \"" . XOOPS_URL . "\")'" );
89
            $indeximage_tray = new XoopsFormElementTray( _AM_WFL_LINK_FSHOWSELECTEDIMAGE, '&nbsp;' );
90
            $indeximage_tray -> addElement( $indeximage_select );
91
            if ( !empty( $imgurl ) ) {
92
                $indeximage_tray -> addElement( new XoopsFormLabel( '', "<br /><br /><img src='" . XOOPS_URL . "/" . $dirarray[$rootpath] . "/" . $linkfile . "' name='image' id='image' alt='' />" ) );
93
            } else {
94
                $indeximage_tray -> addElement( new XoopsFormLabel( '', "<br /><br /><img src='" . XOOPS_URL . "/uploads/blank.gif' name='image' id='image' alt='' />" ) );
95
            }
96
            $iform -> addElement( $indeximage_tray );
97
            $iform -> addElement( new XoopsFormFile( _AM_WFL_LINK_FUPLOADIMAGE, 'uploadfile', 0 ) );
98
            $iform -> addElement( new XoopsFormHidden( 'uploadpath', $dirarray[$rootpath] ) );