<?php
error_reporting(0);
define('INCLUDE_CHECK',true);
session_start();
require ('classes/config2.php');
require_once('classes/session.php');
    $studlevel= $_SESSION['programme'];
    
    if ($studlevel == '%FT230%')
    {
        $level='HND I';
        $ptyp= "FULL TIME";
    }
    elseif ($studlevel == '%PT230%')
    {
        $level='ND I';
        $ptyp= "PART  TIME";
    }
    elseif ($studlevel == '%PU230%')
    {
        $level='ND I';
        $ptyp= "FULL TIME";
    }
?>



<!DOCTYPE html>
<html>
<head>
<title>OSCOTECH | Admitted List</title>
<link href="http://oscotechesaoke.edu.ng/admission_portal/layout/css/bootstrap.login.css" rel="stylesheet" type="text/css" media="all" />
<link href="http://oscotechesaoke.edu.ng/admission_portal/layout/css/login.css" rel="stylesheet" type="text/css" media="all" />		
<link rel="shortcut icon" href="../images/favicon.ico">
<script type="application/x-javascript"> addEventListener("load", function() { setTimeout(hideURLbar, 0); }, false); function hideURLbar(){ window.scrollTo(0,1); } </script>
<link href='http://fonts.googleapis.com/css?family=Open+Sans:400,300,600,700,800' rel='stylesheet' type='text/css'>
<style type="text/css">
div.a {
  text-transform: uppercase;
}

	body{margin-top:40px; padding:0; top:20;}
</style>
</head>
<body>
	<div style="width:97%; margin:20 auto"> 
        <center>
            
             
        <h1 style="font-weight:bold; font-size:25px">OSUN STATE COLLEGE OF TECHNOLOGY, ESA-OKE</h1>
    	<h2 style="font-weight:bold; font-size:16px; text-decoration:underline"><?php echo "2023/2024"?>  STUDENT MATRICULATION LIST REPORT</h2>
        <h2 style="font-weight:bold; font-size:16px;text-decoration:underline">
            <div class="a"> <?php echo $level. "  " .$ptyp. " " .$_SESSION['courses']?> 
            </div></h2>
            
            <h2 style="font-weight:bold; font-size:16px; text-decoration:underline"><?php echo  'EXAMINATION SCORE SHEET'; ?></h2>
            
            
        <br>
        <table class="table table-bordered  table-condensed table-responsive" style="width:750px; font-size:12px" border="1">
        	<thead>
                  <tr height="45" align="left" >
                      
                                            <th>S/N</th>
                                            <th>MATRIC NO</th>
                                            <th>STUDENT NAMES</th>
                                            <th>CA1 SCORE</th>
                                            <th>CA2 SCORE</th>
                                            <th>EXAM SCORE</th>
                                            <th>TOTAL SCORE</th>
                                            <th>REMARK</th>
                                             
                                        </tr>
            </thead>
        					<?php
					 
						    
						   
					 
						
						 
							
                        	if($_POST[fromdate]=="" || $_POST[todate]=="")
                        	{
								$sql = ("SELECT DISTINCT admission_list.formno, admission_list.department,admission_list.names, student_activity_level.formno, student_activity_level.matricno  
								FROM admission_list, student_activity_level  
								      WHERE admission_list.session='2023/2024'
								      AND student_activity_level.formno=admission_list.formno AND student_activity_level.formno LIKE '$_SESSION[programme]' AND admission_list.department='$_SESSION[courses]'  AND student_activity_level.matricno>0  
									 	ORDER BY student_activity_level.matricno  ");
                        	}
                        	$result = $conn1->query($sql);
                        
                        $i=0;
                        //while($row=mysql_fetch_array($sql)){
                         while($row = $result->fetch_assoc()) {
                        $i++;
                        $color=($i%2==0)?"lightblue":"white";
						   						
                    ?>
                                    <tbody height="25" >
                                                                                <tr >
                                        	<td><?php echo $i;?></td>
                                            <td><?php echo $row['matricno'];?></td>
                                            <td>
                                                <div class="a">
                                                <?php echo $row['names'];?>
                                                </div>
                                                </td>
                                            <td> </td>
                                            <td> </td>
                                            <td> </td>
                                            <td> </td>
                                            <td> </td>
                                             
                                             
                                            <?php /*
                                           	 	if($row['type']=='PRO') {
                                                    echo "<td>Provisional Admission</td>";
												}else{
													echo "<td>Concessionary Admission</td>";
												}*/
											?>
                                        </tr>
                                    </tbody>
                          <?php	
							}														
							?>
                                </table>
        
                           
        </center>
    </div>
    	<br>
    <center>
   		<INPUT TYPE="button" class="btn btn-success " VALUE="PRINT" ONCLICK="self.print();">
    </center>
    <br>
</body>
</html>

<?php mysql_close();  ?>