chamilo/chamilo-lms

View on GitHub
public/main/my_space/user_import.php

Summary

Maintainability
A
0 mins
Test Coverage

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

    $id_session = intval($_POST['id_session']);

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

                $course_list = [];

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

        $error_message .= api_get_person_name($error_user['FirstName'], $error_user['LastName']);

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

        $error_message .= api_get_person_name($error_user['FirstName'], $error_user['LastName']);

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

$purification_option_for_usernames = false;

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

                $users = MySpace::check_all_usernames($users, $course_list, $id_session);

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

Display::display_header($tool_name);

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

        $error_message .= api_get_person_name($error_user['FirstName'], $error_user['LastName']);

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

$form->addRule('import_file', get_lang('Invalid extension').' ('.implode(',', $allowed_file_types).')', 'filetype', $allowed_file_types);

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

    $file_type = $_POST['file_type'];

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

    if ('csv' === $file_type) {

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

                    $course_list[] = $row['c_id'];

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

        header('Location: course.php?id_session='.$id_session);

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

    $error_message = '<ul>';

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

$id_session = '';

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

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

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

    $interbreadcrumb[] = ['url' => 'course.php?id_session='.$id_session.'', 'name' => get_lang('Course')];

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

    foreach ($errors as $index => $error_user) {

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

$allowed_file_types = ['xml', 'csv'];

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

            $id_session = intval($_REQUEST['id_session']);

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

                $sql = "SELECT c_id FROM $tbl_session_rel_course WHERE session_id ='$id_session'";

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 "tool_name" is not in valid camel caps format
Open

$tool_name = get_lang('Import users list');

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

            if (!empty($id_session)) {

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

                    MySpace::save_data($users, $course_list, $id_session);

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

$form->addElement('hidden', 'id_session', $id_session);

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

                $sql = "SELECT c_id FROM $tbl_session_rel_course WHERE session_id ='$id_session'";

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

    echo Display::return_message($error_message, 'error', false);

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

$form->addRule('import_file', get_lang('Invalid extension').' ('.implode(',', $allowed_file_types).')', 'filetype', $allowed_file_types);

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

                $users = MySpace::check_all_usernames($users, $course_list, $id_session);

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

                    MySpace::save_data($users, $course_list, $id_session);

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

                header('Location: course.php?id_session='.$id_session);

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

        $error_message .= '<li><strong>'.$error_user['error'].'</strong>: ';

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

    $error_message .= '</ul>';

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

$this_section = SECTION_PLATFORM_ADMIN; // TODO: Platform admin section?

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

        $error_message .= '<li><strong>'.$error_user['error'].'</strong>: ';

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

        $error_message .= '</li>';

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

            $session = api_get_session_entity($id_session);

There are no issues that match your filters.

Category
Status