Added ajax to view 1 so that it validates courses and retrieves electives