$blackout_dates = unserialize(PROFESSOR_NOE_SUBMISSION_BLACKOUT); $upcoming_exams_access_service = $dashboard->fetchUpcomingExams($_GET['student_num']); if (!empty($upcoming_exams_access_service)) { foreach ($upcoming_exams_access_service as $key => $ue) { $upcoming_exams_access_service[$key]['dropped'] = $model->determineDropped($_GET['student_num'], $upcoming_exams_access_service[$key]['course_code'], $upcoming_exams_access_service[$key]['course_section'], $upcoming_exams_access_service[$key]['session']); } } $past_exams_access_service = $model->fetchPastExamsAtAccessService($_GET['student_num']); if (!empty($past_exams_access_service)) { foreach ($past_exams_access_service as &$ueas) { $ueas['dropped'] = $model->determineDropped($_GET['student_num'], $ueas['course_code'], $ueas['course_section'], $ueas['session']); } unset($ueas); } $upcoming_exams_in_class = $model->fetchUpcomingExamsInClass($_GET['student_num']); $student_courses = $student_profile->fetchStudentAllCoursesNeedingConfirmation($_GET['student_num']); foreach ($student_courses as $sc) { //For each course that a student is registered in, find the NOE for which the students can still respond $exams_awaiting_response_for_course = $model->fetchExamsAwaitingResponse($_GET['student_num'], $sc['code'], $sc['section'], $sc['session'], $sc['teaching_method']); if (!empty($exams_awaiting_response_for_course)) { $numberOfExams = sizeof($exams_awaiting_response_for_course); for ($i = 0; $i < $numberOfExams; ++$i) { //Unset = false: Exam will be shown to the user as an exam that is awaiting response $unset = false; //If an exam is within the blackout date range, it has a specific deadline if (strtotime($exams_awaiting_response_for_course[$i]['exam_date']) >= strtotime($blackout_dates['start']) && strtotime($exams_awaiting_response_for_course[$i]['exam_date']) <= strtotime($blackout_dates['end'])) { if (time() > strtotime(PROFESSOR_NOE_SUBMISSION_BLACKOUT_STUDENT_RESPONSE_DEADLINE)) { //Exam is no longer eligible for a response $unset = true; } } else {