if ('delete' == $action&& api_get_multiple_access_url() &&1 != $urlId) {
echo Display::return_message(get_lang('Course categories are global over multiple portals configurations. Changes are only allowed in the main administrative portal.'), 'warning');
$group[] = $form->createElement('radio', 'visibility', get_lang("Course access"), get_lang('Public - access allowed for the whole world'), COURSE_VISIBILITY_OPEN_WORLD);
$group[] = $form->createElement('radio', 'visibility', get_lang('Course access'), get_lang('Public - access allowed for the whole world'), COURSE_VISIBILITY_OPEN_WORLD);
$group[] = $form->createElement('radio', 'visibility', null, get_lang(' Open - access allowed for users registered on the platform'), COURSE_VISIBILITY_OPEN_PLATFORM);
$group[] = $form->createElement('radio', 'visibility', null, get_lang('Private access (access authorized to group members only)'), COURSE_VISIBILITY_REGISTERED);
$group[] = $form->createElement('radio', 'visibility', null, get_lang('Closed - the course is only accessible to the teachers'), COURSE_VISIBILITY_CLOSED);
$form->addElement('radio', 'keyword_visibility', get_lang("Course access"), get_lang('Public - access allowed for the whole world'), COURSE_VISIBILITY_OPEN_WORLD);
$form->addElement('radio', 'keyword_visibility', get_lang('Course access'), get_lang('Public - access allowed for the whole world'), COURSE_VISIBILITY_OPEN_WORLD);
$form->addElement('radio', 'keyword_visibility', null, get_lang(' Open - access allowed for users registered on the platform'), COURSE_VISIBILITY_OPEN_PLATFORM);
$form->addElement('radio', 'keyword_visibility', null, get_lang('Private access (access authorized to group members only) access (access authorized to group members only)'), COURSE_VISIBILITY_REGISTERED);
$form->addElement('radio', 'keyword_visibility', null, get_lang('Closed - the course is only accessible to the teachers'), COURSE_VISIBILITY_CLOSED);
@ -40,7 +40,7 @@ if ($course_validation_feature) {
$is_error_message = true;
}
} elseif (isset($_POST['action'])) {
/**
/*
* Form actions: delete.
*/
switch ($_POST['action']) {
@ -55,6 +55,7 @@ if ($course_validation_feature) {
$message = $success ? get_lang('The selected course requests have been deleted.') : get_lang('Some of the selected course requests have not been deleted due to internal error.');
$is_error_message = !$success;
}
break;
}
}
@ -84,9 +85,9 @@ function get_request_data($from, $number_of_items, $column, $direction)
* Acceptance and creation of the requested course.
*/
if (!empty($accept_course_request)) {
@ -71,7 +71,7 @@ if ($course_validation_feature) {
$is_error_message = true;
}
} elseif (isset($_POST['action'])) {
/**
/*
* Form actions: delete.
*/
switch ($_POST['action']) {
@ -86,6 +86,7 @@ if ($course_validation_feature) {
$message = $success ? get_lang('The selected course requests have been deleted.') : get_lang('Some of the selected course requests have not been deleted due to internal error.');
$is_error_message = !$success;
}
break;
}
}
@ -114,9 +115,9 @@ function get_request_data($from, $number_of_items, $column, $direction)
@ -102,6 +102,7 @@ if ($course_validation_feature) {
$message = $success ? get_lang('The selected course requests have been deleted.') : get_lang('Some of the selected course requests have not been deleted due to internal error.');
$is_error_message = !$success;
}
break;
}
}
@ -152,7 +153,7 @@ function get_request_data($from, $number_of_items, $column, $direction)
WHERE status = ".COURSE_REQUEST_PENDING;
}
if ($keyword != '') {
if ('' != $keyword) {
$sql .= " AND (title LIKE '%".$keyword."%' OR code LIKE '%".$keyword."%' OR visual_code LIKE '%".$keyword."%')";
}
$sql .= " ORDER BY col$column $direction ";
@ -178,7 +179,7 @@ function get_request_data($from, $number_of_items, $column, $direction)
function email_filter($teacher)
{
$teacher = Database::escape_string($teacher);
$sql = "SELECT user_id FROM ".Database::get_main_table(TABLE_MAIN_COURSE_REQUEST)."
$sql = 'SELECT user_id FROM '.Database::get_main_table(TABLE_MAIN_COURSE_REQUEST)."