</div> <div style="text-align:right;width:28%;display:inline-block;vertical-align:top;"> <button style="width:15em;background:#43D14C;" onclick="$('#hl').get(0).click();"> <div><img src="img/icons/glyphicons_free/glyphicons/png/glyphicons-191-circle-plus.png" width="13" height="13" /><font face="Calibri" color="black" size="4"> Create new schedule </font></div></button> </div> <div class="datagrid"> <table> <thead> <tr><th>Academic Year</th><th>Semester Start Date</th><th>Semester End Date</th><th><center>Actions</center></th></tr> </thead> <tbody> <?php $schedule = Schedule::getAllSchedules(); if (count($schedule) > 0) { foreach ($schedule as $key => $value) { $sid = $value->getScheduleId(); echo "<tr>"; echo "<td><a href='schedule_manager2.php?sid={$sid}' >" . $value->getAcademicYear() . " ---- Semester " . $value->getSemesterNo() . "</a></td>"; echo "<td>" . $value->getScheduleStartDate() . "</td>"; echo "<td>" . $value->getScheduleEndDate() . "</td>"; echo "<td><div style='text-align:center;'><button style='width:10em;''> <div><img src='img/icons/glyphicons_free/glyphicons/png/glyphicons-151-edit.png' width='13' height='13' /><font face='Calibri' color='black' size='4'> Edit </font></div></button> <button id='{$sid}' onclick='deleteSchedule(this.id)' style='width:10em;'> <div><img src='img/icons/glyphicons_free/glyphicons/png/glyphicons-17-bin.png' width='13' height='15' /><font face='Calibri' color='black' size='4'> Delete </font></div></button><div></td>"; echo "</tr>"; } } ?> </tbody>
public function viewSchedules() { $schedules = Schedule::getAllSchedules(); require_once 'views/schedule_view.php'; }