Code Duplication    Length = 4-4 lines in 3 locations

main/admin/user_information.php 1 location

@@ 307-310 (lines=4) @@
304
                '<a href="'.$courseInfo['course_public_url'].'?id_session='.$id_session.'">'.
305
                Display::return_icon('course_home.gif', get_lang('CourseHomepage')).'</a>';
306
307
            if ($my_course['status'] == STUDENT) {
308
                $tools .= '<a href="user_information.php?action=unsubscribeSessionCourse&course_code='.$courseInfo['code'].'&user_id='.$userId.'&id_session='.$id_session.'">'.
309
                    Display::return_icon('delete.png', get_lang('Delete')).'</a>';
310
            }
311
312
            $timeSpent = api_time_to_hms(
313
                Tracking :: get_time_spent_on_the_course(

main/course_info/infocours.php 1 location

@@ 179-182 (lines=4) @@
176
    $url =  PDF::get_watermark($course_code);
177
    $form->addText('pdf_export_watermark_text', get_lang('PDFExportWatermarkTextTitle'), false, array('size' => '60'));
178
    $form->addElement('file', 'pdf_export_watermark_path', get_lang('AddWaterMark'));
179
    if ($url != false) {
180
        $delete_url = '<a href="?delete_watermark">'.Display::return_icon('delete.png',get_lang('DelImage')).'</a>';
181
        $form->addElement('html', '<div class="row"><div class="formw"><a href="'.$url.'">'.$url.' '.$delete_url.'</a></div></div>');
182
    }
183
    $form->addRule('pdf_export_watermark_path', get_lang('OnlyImagesAllowed').' ('.implode(',', $allowed_picture_types).')', 'filetype', $allowed_picture_types);
184
}
185

main/inc/lib/document.lib.php 1 location

@@ 5353-5356 (lines=4) @@
5350
                            Display::return_icon($forcedownload_icon, get_lang('Download'), array(), ICON_SIZE_SMALL) . '</a>';
5351
                    }
5352
                }
5353
            } else {
5354
                $force_download_html = ($size == 0) ? '' : '<a href="' . $forcedownload_link . '" style="float:right"' . $prevent_multiple_click . ' download="' . $document_data['basename'] . '">' .
5355
                    Display::return_icon($forcedownload_icon, get_lang('Download'), array(), ICON_SIZE_SMALL) . '</a>';
5356
            }
5357
5358
            // Copy files to user's myfiles
5359
            if (api_get_setting('allow_my_files') === 'true' &&