Code Duplication    Length = 3-6 lines in 4 locations

main/gradebook/exercise_jump.php 1 location

@@ 71-73 (lines=3) @@
68
                    if ($count == 1) {
69
                        // If the exercise was added once redirect to the LP
70
                        $firstLp = current($exercise->lpList);
71
                        if (isset($firstLp['lp_id'])) {
72
                            $url = api_get_path(WEB_CODE_PATH).'lp/lp_controller.php?'.api_get_cidreq().'&lp_id='.$firstLp['lp_id'].'&action=view&isStudentView=true';
73
                        }
74
                    } else {
75
                        // If the exercise was added multiple times show the LP list
76
                        $url = api_get_path(WEB_CODE_PATH).'lp/lp_controller.php?'.api_get_cidreq().'&action=list';

main/work/work.lib.php 1 location

@@ 2170-2175 (lines=6) @@
2167
2168
                $correction = '';
2169
                $hasCorrection = '';
2170
                if (!empty($work['url_correction'])) {
2171
                    $hasCorrection = Display::url(
2172
                        $correctionIcon,
2173
                        api_get_path(WEB_CODE_PATH).'work/download.php?id='.$item_id.'&'.api_get_cidreq().'&correction=1'
2174
                    );
2175
                }
2176
2177
                if ($qualification_exists) {
2178
                    $work['qualification'] = $qualification_string.$feedback;

main/ticket/tickets.php 1 location

@@ 276-279 (lines=4) @@
273
    $ticketLabel = get_lang('AllTickets');
274
    $url = api_get_path(WEB_CODE_PATH).'ticket/tickets.php?project_id='.$projectId;
275
276
    if (!isset($_GET['keyword_assigned_to'])) {
277
        $ticketLabel = get_lang('MyTickets');
278
        $url = api_get_path(WEB_CODE_PATH).'ticket/tickets.php?project_id='.$projectId.'&keyword_assigned_to='.api_get_user_id();
279
    }
280
281
    $options = '';
282
    if ($isAdmin) {

main/forum/forumfunction.inc.php 1 location

@@ 4133-4135 (lines=3) @@
4130
    $_course = api_get_course_info();
4131
    $user_id = api_get_user_id();
4132
    $subject = get_lang('NewForumPost').' - '.$_course['official_code'];
4133
    if (isset($thread_information) && is_array($thread_information)) {
4134
        $thread_link = api_get_path(WEB_CODE_PATH).'forum/viewthread.php?'.api_get_cidreq().'&forum='.$thread_information['forum_id'].'&thread='.$thread_information['thread_id'];
4135
    }
4136
    $email_body = get_lang('Dear').' '.api_get_person_name($user_info['firstname'], $user_info['lastname'], null, PERSON_NAME_EMAIL_ADDRESS).", <br />\n\r";
4137
    $email_body .= get_lang('NewForumPost')."\n";
4138
    $email_body .= get_lang('Course').': '.$_course['name'].' - ['.$_course['official_code']."] - <br />\n";