Code Duplication    Length = 4-13 lines in 13 locations

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

@@ 383-386 (lines=4) @@
380
381
        $actionsLeft .= '<a href="index.php?'.api_get_cidreq().'&action=export">'.
382
            Display::return_icon('export_csv.png', get_lang('ExportGlossaryAsCSV'), '', ICON_SIZE_MEDIUM).'</a>';
383
        if (api_is_allowed_to_edit(null, true)) {
384
            $actionsLeft .= '<a href="index.php?'.api_get_cidreq().'&action=import">'.
385
                Display::return_icon('import_csv.png', get_lang('ImportGlossary'), '', ICON_SIZE_MEDIUM).'</a>';
386
        }
387
388
        $actionsLeft .= '<a href="index.php?'.api_get_cidreq().'&action=export_to_pdf">'.
389
            Display::return_icon('pdf.png', get_lang('ExportToPDF'), '', ICON_SIZE_MEDIUM).'</a>';

src/Chamilo/CoreBundle/Framework/PageController.php 1 location

@@ 1132-1143 (lines=12) @@
1129
                                    $session
1130
                                );
1131
                                $params['right_actions'] = '';
1132
                                if (api_is_platform_admin()) {
1133
                                    $params['right_actions'] .=
1134
                                        Display::url(
1135
                                            Display::return_icon(
1136
                                                'edit.png',
1137
                                                get_lang('Edit'),
1138
                                                array('align' => 'absmiddle'),
1139
                                                ICON_SIZE_SMALL
1140
                                            ),
1141
                                            api_get_path(WEB_CODE_PATH).'session/resume_session.php?id_session='.$session_id
1142
                                        );
1143
                                }
1144
1145
                                if (api_get_setting('session.hide_courses_in_sessions') == 'false') {
1146
                                    //    $params['extra'] .=  $html_courses_session;

main/install/install.lib.php 1 location

@@ 727-739 (lines=13) @@
724
    echo '<div class="RequirementHeading"><h4>'.get_lang('ServerRequirements').'</h4>';
725
726
    $timezone = checkPhpSettingExists("date.timezone");
727
    if (!$timezone) {
728
        echo "<div class='alert alert-warning'>".
729
            Display::return_icon(
730
                'warning.png',
731
                get_lang('Warning'),
732
                '',
733
                ICON_SIZE_MEDIUM,
734
                true,
735
                false,
736
                false
737
            ).
738
            get_lang("DateTimezoneSettingNotSet")."</div>";
739
    }
740
741
    echo '<div class="RequirementText">'.get_lang('ServerRequirementsInfo').'</div>';
742
    echo '<div class="RequirementContent">';

main/admin/course_list.php 1 location

@@ 398-403 (lines=6) @@
395
        api_get_path(WEB_CODE_PATH).'admin/course_add.php'
396
    );
397
398
    if (api_get_setting('course_validation') === 'true') {
399
        $actions1 .= Display::url(
400
            Display::return_icon('course_request_pending.png', get_lang('ReviewCourseRequests'), [], ICON_SIZE_MEDIUM),
401
            api_get_path(WEB_CODE_PATH).'admin/course_request_review.php'
402
        );
403
    }
404
405
    $actions2 = $form->returnForm();
406
    $actions3 = $sessionFilter->returnForm();

main/admin/user_list.php 2 locations

@@ 628-633 (lines=6) @@
625
626
    $allowAssignSkill = api_is_platform_admin(false, true);
627
628
    if ($allowAssignSkill) {
629
        $result .= Display::url(
630
            Display::return_icon('skill-badges.png', get_lang('AssignSkill'), null, ICON_SIZE_SMALL),
631
            api_get_path(WEB_CODE_PATH).'badge/assign.php?'.http_build_query(['user' => $user_id])
632
        );
633
    }
634
635
	if ($is_admin) {
636
        $result .= Display::return_icon(
@@ 846-849 (lines=4) @@
843
$actionsLeft = '';
844
$actionsCenter = '';
845
$actionsRight  = '';
846
if (api_is_platform_admin()) {
847
	$actionsRight .= '<a class="pull-right" href="'.api_get_path(WEB_CODE_PATH).'admin/user_add.php">'.
848
         Display::return_icon('new_user.png', get_lang('AddUsers'), '', ICON_SIZE_MEDIUM).'</a>';
849
}
850
851
$actionsLeft .= $form->returnForm();
852
$actionsCenter .= $searchAdvanced;

main/attendance/attendance_sheet.php 1 location

@@ 409-416 (lines=8) @@
406
                </div>
407
        </form>
408
    <?php
409
    } else {
410
        echo Display::return_message(
411
            '<a href="'.api_get_path(WEB_CODE_PATH).'user/user.php?'.api_get_cidreq().'">'.
412
            get_lang('ThereAreNoRegisteredLearnersInsidetheCourse').'</a>',
413
            'warning',
414
            false
415
        );
416
    }
417
} else {
418
    echo Display::page_header(get_lang('AttendanceSheetReport'));
419
    // View for students

main/document/document.php 3 locations

@@ 1709-1714 (lines=6) @@
1706
            api_get_path(WEB_CODE_PATH).'document/upload.php?'.api_get_cidreq()
1707
                .'&id='.$current_folder_id.'&certificate=true'
1708
        );
1709
    } else {
1710
        $actionsLeft .= Display::url(
1711
            Display::return_icon('upload_file.png', get_lang('UplUploadDocument'), '', ICON_SIZE_MEDIUM),
1712
            api_get_path(WEB_CODE_PATH).'document/upload.php?'.api_get_cidreq().'&id='.$current_folder_id
1713
        );
1714
    }
1715
1716
    /*echo '<a href="#" id="jcapture">';
1717
    echo Display::display_icon('capture.png', get_lang('CatchScreenCasts'), '', ICON_SIZE_MEDIUM).'</a>';*/
@@ 1745-1750 (lines=6) @@
1742
    );
1743
}
1744
1745
if ($isAllowedToEdit) {
1746
    $actionsLeft .= Display::url(
1747
        Display::return_icon('percentage.png', get_lang('DocumentQuota'), '', ICON_SIZE_MEDIUM),
1748
        api_get_path(WEB_CODE_PATH).'document/document_quota.php?'.api_get_cidreq()
1749
    );
1750
}
1751
1752
if (!$is_certificate_mode) {
1753
    /* BUILD SEARCH FORM */
@@ 1979-1985 (lines=7) @@
1976
}
1977
1978
if (api_is_platform_admin()) {
1979
    if (api_get_configuration_value('document_manage_deleted_files')) {
1980
        $actionsLeft .= Display::url(
1981
            get_lang('Recycle'),
1982
            api_get_path(WEB_CODE_PATH).'document/recycle.php?'.api_get_cidreq(),
1983
            array('class' => 'btn btn-default')
1984
        );
1985
    }
1986
}
1987
1988
if (!empty($moveTo)) {

main/forum/index.php 1 location

@@ 197-207 (lines=11) @@
194
        api_get_self().'?'.api_get_cidreq().'&action=add&content=forumcategory&lp_id='.$lp_id
195
    );
196
197
    if (is_array($forumCategories) && !empty($forumCategories)) {
198
        $actionLeft .= Display::url(
199
            Display::return_icon(
200
                'new_forum.png',
201
                get_lang('AddForum'),
202
                null,
203
                ICON_SIZE_MEDIUM
204
            ),
205
            api_get_self().'?'.api_get_cidreq().'&action=add&content=forum&lp_id='.$lp_id
206
        );
207
    }
208
}
209
210
$actions = Display::toolbarAction('toolbar-forum', array($actionLeft));

main/tracking/courseLog.php 1 location

@@ 235-240 (lines=6) @@
232
    api_get_path(WEB_CODE_PATH).'tracking/exams.php?'.api_get_cidreq()
233
);
234
235
if (!empty($sessionId)) {
236
    $actionsLeft .= Display::url(
237
        Display::return_icon('attendance_list.png', get_lang('Logins'), '', ICON_SIZE_MEDIUM),
238
        api_get_path(WEB_CODE_PATH).'attendance/index.php?'.api_get_cidreq().'&action=calendar_logins'
239
    );
240
}
241
242
$actionsRight = '<div class="pull-right">';
243
$actionsRight .= '<a href="javascript: void(0);" onclick="javascript: window.print();">'.

main/user/user.php 1 location

@@ 606-609 (lines=4) @@
603
    $actions .= '<a href="user.php?'.api_get_cidreq().'&action=export&format=xls&type='.$type.'">'.
604
        Display::return_icon('export_excel.png', get_lang('ExportAsXLS'), [], ICON_SIZE_MEDIUM).'</a> ';
605
606
    if ($canEditUsers) {
607
        $actions .= '<a href="user_import.php?'.api_get_cidreq().'&action=import">'.
608
            Display::return_icon('import_csv.png', get_lang('ImportUsersToACourse'), [], ICON_SIZE_MEDIUM).'</a> ';
609
    }
610
611
    $actions .= '<a href="user.php?'.api_get_cidreq().'&action=export&format=pdf&type='.$type.'">'.
612
        Display::return_icon('pdf.png', get_lang('ExportToPDF'), [], ICON_SIZE_MEDIUM).'</a> ';