$show_name = mysqli_query($conn, "select name from tbl_system_name") or die(mysqli_error($conn)); if (mysqli_num_rows($show_name) == 0) { mysqli_query($conn, "insert into tbl_system_name values('','Online Grading Assistant with Mobile Inquiry System for Kto12')") or die(mysqli_error($conn)); } else { while ($row = mysqli_fetch_array($show_name)) { echo "{$row['name']}"; } } ?> </p></div> <div id="s2"> </div> </div> <div id="event-header"> <?php echo "Grade {$grade}- Section (" . get_section_by_desc($section) . ')'; if (isset($_POST['advisory'])) { echo "<span style='font-size:15px;'><br/>Adviser: <a style='color:red'>YOU</a></span>"; } ?> </div> <div id="event-wrap"> <div id='events-page'> <?php if (isset($_SESSION['x'])) { if ($_SESSION['x'] == 1) { echo "<center style='color:red;'>No. of Students Allowed to Put in the class record , ranges 1 to 60 (1-60) only.</center>"; $_SESSION['x'] = 0; } elseif ($_SESSION['x'] == 2) { echo "<center style='color:red;'>Class Record Already Exist!</center>";
$ws_cols = $row['ws_cols']; $pt_cols = $row['pt_cols']; } } else { $_SESSION['x'] = 1; exit(header("location:grading_index_faculty.php")); } ?> <table width='100%' cellpadding='10px' border='2'> <tr> <th colspan='1000'align="center"><b style="font-size:18px;"> <?php echo $sy . '<br>'; echo grading_translator($g_period) . '<br/>'; echo 'CLASS RECORD IN - ' . getSubjDesc($subj_code) . '<br/>'; echo 'Grade & Section: Grade ' . $grade_id . '- (' . get_section_by_desc($section_id) . ')'; ?> </b> </th> </tr> <?php $cols = ""; $colsel = genSelect($ws_cols, 'w'); $total_item = 0; $item_query = mysqli_query($conn, "select {$colsel},wtotal,wps from class_record_items where class_record_id='{$id}' and school_id='{$_SESSION['school_id']}'") or die(mysqli_error($conn)); if (mysqli_num_rows($item_query) > 0) { while ($items = mysqli_fetch_array($item_query)) { ?> <tr> <td> </td> <td style="width:auto;">Name</td>