$discovery->referrals = $_POST['e_referrals'];
        $discovery->others = $_POST['e_others'];
        $discovery->update();
        //----------------------------------------------------------------------------------------------------------------------------------//
        $enrollmentDetail = EnrollmentDetail::get_by_id($student->enrollment_detail_id);
        $enrollmentDetail->status = $_POST['f_status'];
        $enrollmentDetail->program = $_POST['f_program'];
        $enrollmentDetail->schedule = $_POST['f_schedule'];
        $enrollmentDetail->payment = $_POST['f_payment'];
        $enrollmentDetail->studentcontactnumber = $_POST['f_studentcontactnumber'];
        $enrollmentDetail->update();
        //----------------------------------------------------------------------------------------------------------------------------------//
        $appointmentDetail = AppointmentDetail::get_by_id($student->appointment_detail_id);
        $appointmentDetail->visitschedule = strtotime($_POST['g_visitschedule']);
        $appointmentDetail->visitpurpose = $_POST['g_visitpurpose'];
        $appointmentDetail->officer = $_POST['g_officer'];
        $appointmentDetail->update();
        //----------------------------------------------------------------------------------------------------------------------------------//
    } else {
        if ($_POST['oper'] == 'del') {
            $student = Student::get_by_id($_POST['id']);
            $student->delete();
            AppointmentDetail::get_by_id($student->appointment_detail_id)->delete();
            EnrollmentDetail::get_by_id($student->enrollment_detail_id)->delete();
            StiDiscovery::get_by_id($student->sti_discovery_id)->delete();
            SchoolConsidered::get_by_id($student->school_considered_id)->delete();
            SchoolLastAttended::get_by_id($student->school_last_attended_id)->delete();
            PersonalInformation::get_by_id($student->personal_information_id)->delete();
        }
    }
}
 if (!$inquiry) {
     $inquiry = new Inquiry();
 }
 $s .= "<cell>" . $inquiry->tuition . "</cell>";
 $s .= "<cell>" . $inquiry->program . "</cell>";
 $s .= "<cell>" . $inquiry->others . "</cell>";
 //----------------------------------------------------------------------------------------------------------------------------------//
 $schoolConsidered = SchoolConsidered::get_by_id($student->school_considered_id);
 if (!$schoolConsidered) {
     $schoolConsidered = new SchoolConsidered();
 }
 $s .= "<cell>" . $schoolConsidered->first . "</cell>";
 $s .= "<cell>" . $schoolConsidered->second . "</cell>";
 $s .= "<cell>" . $schoolConsidered->third . "</cell>";
 //----------------------------------------------------------------------------------------------------------------------------------//
 $discovery = StiDiscovery::get_by_id($student->sti_discovery_id);
 if (!$discovery) {
     $discovery = new StiDiscovery();
 }
 $s .= "<cell>" . $discovery->tv . "</cell>";
 $s .= "<cell>" . $discovery->radio . "</cell>";
 $s .= "<cell>" . $discovery->print . "</cell>";
 $s .= "<cell>" . $discovery->website . "</cell>";
 $s .= "<cell>" . $discovery->seminar . "</cell>";
 $s .= "<cell>" . $discovery->careerfactor . "</cell>";
 $s .= "<cell>" . $discovery->event . "</cell>";
 $s .= "<cell>" . $discovery->flyers . "</cell>";
 $s .= "<cell>" . $discovery->billboards . "</cell>";
 $s .= "<cell>" . $discovery->posters . "</cell>";
 $s .= "<cell>" . $discovery->stimuli . "</cell>";
 $s .= "<cell>" . $discovery->referrals . "</cell>";