chamilo/chamilo-lms

View on GitHub
public/main/user/resume_session.php

Summary

Maintainability
A
0 mins
Test Coverage

Variable "id_session" is not in valid camel caps format
Open

SessionManager::protect_teacher_session_edit($id_session);

Variable "tbl_course" is not in valid camel caps format
Open

    $tbl_course = Database::get_main_table(TABLE_MAIN_COURSE);

Variable "tbl_user" is not in valid camel caps format
Open

    $tbl_user = Database::get_main_table(TABLE_MAIN_USER);

Variable "tbl_session_rel_course_rel_user" is not in valid camel caps format
Open

    $tbl_session_rel_course_rel_user = Database::get_main_table(TABLE_MAIN_SESSION_COURSE_USER);

Variable "tool_name" is not in valid camel caps format
Open

$tool_name = get_lang('Session overview');

Variable "id_session" is not in valid camel caps format
Open

    $session = api_get_session_entity($id_session);

Variable "url_id" is not in valid camel caps format
Open

    $url_id = api_get_current_access_url_id();

Variable "tbl_session_rel_course" is not in valid camel caps format
Open

    $tbl_session_rel_course = Database::get_main_table(TABLE_MAIN_SESSION_COURSE);

Variable "id_session" is not in valid camel caps format
Open

$id_session = (int) $_GET['id_session'];

Variable "tbl_session" is not in valid camel caps format
Open

    $tbl_session = Database::get_main_table(TABLE_MAIN_SESSION);

Variable "tbl_session_category" is not in valid camel caps format
Open

    $tbl_session_category = Database::get_main_table(TABLE_MAIN_SESSION_CATEGORY);

Variable "this_section" is not in valid camel caps format
Open

$this_section = SECTION_PLATFORM_ADMIN;

Variable "tbl_session_rel_user" is not in valid camel caps format
Open

    $tbl_session_rel_user = Database::get_main_table(TABLE_MAIN_SESSION_USER);

Spaces must be used for alignment; tabs are not allowed
Open

 *    @author Bart Mollet, Julio Montoya lot of fixes

Variable "tbl_session_rel_class" is not in valid camel caps format
Open

    $tbl_session_rel_class = Database::get_main_table(TABLE_MAIN_SESSION_CLASS);

Variable "table_access_url_user" is not in valid camel caps format
Open

    $table_access_url_user = Database::get_main_table(TABLE_MAIN_ACCESS_URL_REL_USER);

Variable "user_id" is not in valid camel caps format
Open

            $user_id = $_REQUEST['user_id'];

Variable "tbl_session" is not in valid camel caps format
Open

                Database::query("UPDATE $tbl_session SET nbr_courses=nbr_courses-$nbr_affected_rows WHERE id='$id_session'");

Variable "id_session" is not in valid camel caps format
Open

                $result = Database::query("DELETE FROM $tbl_session_rel_class WHERE session_id='$id_session' AND class_id=".intval($_GET['class']));

Variable "id_session" is not in valid camel caps format
Open

                $result = Database::query("DELETE FROM $tbl_session_rel_course_rel_user WHERE session_id ='$id_session' AND user_id=".intval($_GET['user']));

Variable "tool_name" is not in valid camel caps format
Open

    Display::display_header($tool_name);

Variable "id_session" is not in valid camel caps format
Open

        $url_list = UrlManager::get_access_url_from_session($id_session);

Variable "orig_param" is not in valid camel caps format
Open

                        <a href="../my_space/myStudents.php?student='.$user['user_id'].''.$orig_param.'">'.

Variable "url_list" is not in valid camel caps format
Open

        $url_list = UrlManager::get_access_url_from_session($id_session);

Variable "id_session" is not in valid camel caps format
Open

                        <a href="session_course_user.php?id_user='.$user['user_id'].'&id_session='.$id_session.'">'.

Variable "user_info" is not in valid camel caps format
Open

                            $user_info['lastname']

Variable "my_temp" is not in valid camel caps format
Open

                    $my_temp[] = $courseInfo['real_id']; // forcing the escape_string

Variable "nbr_affected_rows" is not in valid camel caps format
Open

                $nbr_affected_rows = Database::affected_rows($result);

Variable "id_session" is not in valid camel caps format
Open

                Database::query("UPDATE $tbl_session SET nbr_classes=nbr_classes-$nbr_affected_rows WHERE id='$id_session'");

Variable "url_list" is not in valid camel caps format
Open

        foreach ($url_list as $url_data) {

Variable "link_to_add_user_in_url" is not in valid camel caps format
Open

            $link_to_add_user_in_url = '';

Variable "url_id" is not in valid camel caps format
Open

                if ($user['access_url_id'] != $url_id) {

Variable "id_session" is not in valid camel caps format
Open

                $result = Database::query("DELETE FROM $tbl_session_rel_course WHERE session_id='$id_session' AND c_id IN($idChecked)");

Variable "id_session" is not in valid camel caps format
Open

                Database::query("DELETE FROM $tbl_session_rel_course_rel_user WHERE session_id='$id_session' AND c_id IN($idChecked)");

Variable "tbl_session" is not in valid camel caps format
Open

                Database::query("UPDATE $tbl_session SET nbr_users=nbr_users-$nbr_affected_rows WHERE id='$id_session'");

Variable "url_id" is not in valid camel caps format
Open

                    WHERE u.active <> ".USER_SOFT_DELETED." AND su.session_id = $id_session AND (access_url_id = $url_id OR access_url_id is null )

Variable "id_session" is not in valid camel caps format
Open

                    $link_to_add_user_in_url = '<a href="resume_session.php?action=add_user_to_url&id_session='.$id_session.'&user_id='.$user['user_id'].'">'.$add.'</a>';

Variable "user_id" is not in valid camel caps format
Open

            $result = UrlManager::add_user_to_url($user_id, $url_id);

Variable "user_info" is not in valid camel caps format
Open

            $user_info = api_get_user_info($user_id);

Variable "user_link" is not in valid camel caps format
Open

                $user_link = '<a

Variable "multiple_url_is_on" is not in valid camel caps format
Open

            if ($multiple_url_is_on) {

Variable "nbr_affected_rows" is not in valid camel caps format
Open

                Database::query("UPDATE $tbl_session SET nbr_courses=nbr_courses-$nbr_affected_rows WHERE id='$id_session'");

Variable "tbl_session_rel_class" is not in valid camel caps format
Open

                $result = Database::query("DELETE FROM $tbl_session_rel_class WHERE session_id='$id_session' AND class_id=".intval($_GET['class']));

Variable "id_session" is not in valid camel caps format
Open

                Database::query("UPDATE $tbl_session SET nbr_users=nbr_users-$nbr_affected_rows WHERE id='$id_session'");

Variable "tbl_session_rel_course_rel_user" is not in valid camel caps format
Open

                $result = Database::query("DELETE FROM $tbl_session_rel_course_rel_user WHERE session_id ='$id_session' AND user_id=".intval($_GET['user']));

Variable "tbl_session_rel_user" is not in valid camel caps format
Open

                    INNER JOIN $tbl_session_rel_user su

Variable "tbl_session_rel_user" is not in valid camel caps format
Open

                    INNER JOIN $tbl_session_rel_user su

Variable "nbr_affected_rows" is not in valid camel caps format
Open

                $nbr_affected_rows = Database::affected_rows($result);

Variable "multiple_url_is_on" is not in valid camel caps format
Open

    if ($multiple_url_is_on) {

Variable "tbl_user" is not in valid camel caps format
Open

                    FROM $tbl_user u

Variable "order_clause" is not in valid camel caps format
Open

                    $order_clause";

Variable "user_link" is not in valid camel caps format
Open

                        '.$user_link.'

Variable "user_info" is not in valid camel caps format
Open

                            $user_info['firstname'],

Variable "id_session" is not in valid camel caps format
Open

                $result = Database::query("DELETE FROM $tbl_session_rel_user WHERE relation_type = ".Session::STUDENT." AND session_id ='$id_session' AND user_id=".intval($_GET['user']));

Variable "url_data" is not in valid camel caps format
Open

            echo $url_data['url'].'<br />';

Variable "id_session" is not in valid camel caps format
Open

                    WHERE u.active <> ".USER_SOFT_DELETED." AND su.session_id = $id_session AND (access_url_id = $url_id OR access_url_id is null )

Closing brace indented incorrectly; expected 0 spaces, found 4
Open

    }

Variable "my_temp" is not in valid camel caps format
Open

                $my_temp = [];

Variable "my_temp" is not in valid camel caps format
Open

                $idChecked = $my_temp;

Variable "nbr_affected_rows" is not in valid camel caps format
Open

                Database::query("UPDATE $tbl_session SET nbr_users=nbr_users-$nbr_affected_rows WHERE id='$id_session'");

Variable "tbl_session" is not in valid camel caps format
Open

                Database::query("UPDATE $tbl_session SET nbr_classes=nbr_classes-$nbr_affected_rows WHERE id='$id_session'");

Variable "nbr_affected_rows" is not in valid camel caps format
Open

                $nbr_affected_rows = Database::affected_rows($result);

Variable "order_clause" is not in valid camel caps format
Open

                    AND su.session_id = ".$id_session." WHERE u.active <> ".USER_SOFT_DELETED.$order_clause;

Variable "link_to_add_user_in_url" is not in valid camel caps format
Open

                        '.$link_to_add_user_in_url.'

Variable "url_id" is not in valid camel caps format
Open

            $result = UrlManager::add_user_to_url($user_id, $url_id);

Variable "tbl_session_rel_course" is not in valid camel caps format
Open

                $result = Database::query("DELETE FROM $tbl_session_rel_course WHERE session_id='$id_session' AND c_id IN($idChecked)");

Variable "tbl_session_rel_course_rel_user" is not in valid camel caps format
Open

                Database::query("DELETE FROM $tbl_session_rel_course_rel_user WHERE session_id='$id_session' AND c_id IN($idChecked)");

Variable "tbl_session_rel_course" is not in valid camel caps format
Open

                Database::query("UPDATE $tbl_session_rel_course SET nbr_users=nbr_users-$nbr_affected_rows WHERE session_id ='$id_session'");

Variable "nbr_affected_rows" is not in valid camel caps format
Open

                Database::query("UPDATE $tbl_session_rel_course SET nbr_users=nbr_users-$nbr_affected_rows WHERE session_id ='$id_session'");

Variable "url_data" is not in valid camel caps format
Open

        foreach ($url_list as $url_data) {

Variable "tbl_user" is not in valid camel caps format
Open

                    FROM $tbl_user u

Variable "tbl_session_rel_user" is not in valid camel caps format
Open

                $result = Database::query("DELETE FROM $tbl_session_rel_user WHERE relation_type = ".Session::STUDENT." AND session_id ='$id_session' AND user_id=".intval($_GET['user']));

Variable "nbr_affected_rows" is not in valid camel caps format
Open

                $nbr_affected_rows = Database::affected_rows($result);

Variable "id_session" is not in valid camel caps format
Open

                Database::query("UPDATE $tbl_session_rel_course SET nbr_users=nbr_users-$nbr_affected_rows WHERE session_id ='$id_session'");

Variable "table_access_url_user" is not in valid camel caps format
Open

                    LEFT OUTER JOIN $table_access_url_user uu ON (uu.user_id = u.id)

Variable "id_session" is not in valid camel caps format
Open

                    AND su.session_id = ".$id_session." WHERE u.active <> ".USER_SOFT_DELETED.$order_clause;

Variable "nbr_affected_rows" is not in valid camel caps format
Open

                Database::query("UPDATE $tbl_session SET nbr_classes=nbr_classes-$nbr_affected_rows WHERE id='$id_session'");

Variable "multiple_url_is_on" is not in valid camel caps format
Open

    $multiple_url_is_on = api_get_multiple_access_url();

Variable "link_to_add_user_in_url" is not in valid camel caps format
Open

                    $link_to_add_user_in_url = '<a href="resume_session.php?action=add_user_to_url&id_session='.$id_session.'&user_id='.$user['user_id'].'">'.$add.'</a>';

Variable "user_id" is not in valid camel caps format
Open

            $user_info = api_get_user_info($user_id);

Variable "id_session" is not in valid camel caps format
Open

                Database::query("UPDATE $tbl_session SET nbr_courses=nbr_courses-$nbr_affected_rows WHERE id='$id_session'");

Variable "order_clause" is not in valid camel caps format
Open

        $order_clause = api_sort_by_first_name() ? ' ORDER BY firstname, lastname' : ' ORDER BY lastname, firstname';

Variable "multiple_url_is_on" is not in valid camel caps format
Open

        if ($multiple_url_is_on) {

Variable "orig_param" is not in valid camel caps format
Open

        $orig_param = '&origin=resume_session&id_session='.$id_session;

Variable "id_session" is not in valid camel caps format
Open

        $orig_param = '&origin=resume_session&id_session='.$id_session;

Variable "user_link" is not in valid camel caps format
Open

            $user_link = '';

Variable "user_link" is not in valid camel caps format
Open

                    $user_link .= ' '.Display::getMdiIcon('alert', 'ch-tool-icon', null, ICON_SIZE_SMALL, get_lang('Users not added to the URL'));

Variable "id_session" is not in valid camel caps format
Open

                        <a href="'.api_get_self().'?id_session='.$id_session.'&action=delete&user='.$user['user_id'].'" onclick="javascript:if(!confirm(\''.get_lang('Please confirm your choice').'\')) return false;">'.

Line indented incorrectly; expected 0 spaces, found 4
Open

    }

Expected 0 spaces before closing bracket; newline found
Open

        Display::getMdiIcon('google-classroom', 'ch-tool-icon', null, ICON_SIZE_SMALL, get_lang('Session')

Closing brace indented incorrectly; expected 0 spaces, found 4
Open

    }

There are no issues that match your filters.

Category
Status