<?php
  if (!isset($con)) {
    include "../database_con.php";
    include "inc/bn.php";
}
?>
<!DOCTYPE html>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
  <meta http-equiv="X-UA-Compatible" content="IE=edge">
  <title>শিক্ষকদের নামের তালিকা</title>
  <!-- Tell the browser to be responsive to screen width -->
  <meta content="width=device-width, initial-scale=1, maximum-scale=1, user-scalable=no" name="viewport">
  <!-- Bootstrap 3.3.7 -->
  
  <!-- Font Awesome -->
  <link rel="stylesheet" href="bower_components/font-awesome/css/font-awesome.min.css">
  <!-- Ionicons -->
  <link rel="stylesheet" href="bower_components/Ionicons/css/ionicons.min.css">
  <!-- Theme style -->
  <link rel="stylesheet" href="dist/css/AdminLTE.min.css">
    <link rel="shortcut icon" href="img/favicon.ico">
	<style type="text/css">
	body{margin:0;}
#sl{text-align: center;font-size: 20px; width: 65px;}
#right {text-align:right; font-size: 20px;font-weight:bold;}
#bold {font-size: 20px;font-weight:bold; text-align:center;}
#rightt {font-size: 20px; text-align:right;}	
#footer { background-color:; height:40px; border-bottom:hidden; border-left:hidden; border-right:hidden; }
#examiner { width:15%; float:left; text-align:right; margin-right:30px; border-top:1px solid #000000; text-align:center;}
#signature { height:70px;}
#space { width:61%; float:left;}
#date{position: absolute; right: 209px; position: absolute; top: 79px;}
.print-area{width:850px; height:1050px; margin:auto; box-sizing:border-box; page-break-ofter:always;}
.header,.print-area{text-align: center;}
.header h1 {margin:0px; padding:0px; font-size: 35px;}
.header h3 {margin:0px; padding:0px; font-size: 25px;}
.header h2 {margin:0px; padding:0px; font-size: 20px;}
#heding {font-size: 30px; margin:0; text-align: center;}
#center_font {font-family:SutonnyMJ; text-align: center;}
#name {font-family:SutonnyMJ; text-align: left; width: 230px;}

th, td {  font-size: 20px; font-family:SutonnyMJ;}
#daerr {font-size: 20px;}
#sin {font-size: 20px; height: 36px;}
#nameS {font-size: 20px; height: 36px; width: 268px;}
#id_admission {font-size: 20px; height: 36px; width: 123px;}
#fee {font-size: 20px; height: 36px; width: 170px;}
#sinee {font-size: 20px; height: 36px; width: 200px;}

table{border-collapse:collapse;}
</style>
</head>
 <?php
 //
 $date= date("d-m-Y");

$data="";
$total="";
$notis="";
$sl=1;
//ছাত্রদের তথ্য



?>
<body >
  <div class="col-md-12 printable" id="pagewidth">
    <br>
    <div class="col-md-12" style="text-align: center;">	
</head>
<body>
	<div class="header">
		<h1><?php echo madrasa_name?></h1>
		<h3><?php echo madrasa_address?></h3>
		<tr><th colspan="6" ><h1 style="padding-bottom:10px;">শিক্ষকদের নামের তালিকা</h1></th></tr>  		
	</div>
<tr>
    <td id="daerr"></td>
</tr>                 
<table width="99%" align="center" border="1">
     <thead style="background-color:silver !important; text-align: center;">
     <tr>               
                  <th style="text-align: center;">ক্রমিক</th>
                  <th style="text-align: center;">নাম</th>           
                  <th style="text-align: center;">পদবী</th>
                  <th style="text-align: center;">গ্রাম</th>
                  <th style="text-align: center;">থানা</th>
                  <th style="text-align: center;">জেলা</th>
                  <th style="text-align: center;">মোবাইল</th>
                  <th style="text-align: center;">বেতন</th>
                </tr>
                </thead>
                <tbody>

				</tbody>
			
<?php
$i=1;
   $staff_division=mysqli_query($con,"SELECT distinct * FROM `teacher_view`
  WHERE  status=1 group by staff_division ORDER BY staff_division ASC "); 
    
   while($row_class = mysqli_fetch_assoc($staff_division)){           
   echo "<tr style='background-color:#bdc3bf75; text-align: center;'><td colspan='8' id='class'>$row_class[staff_division_name]</td></tr>";   
              
 //শিক্ষক
     $result=mysqli_query($con,"SELECT  * FROM `teacher_view` 
     
     where staff_division='$row_class[staff_division]' AND status=1  ");
     while($row = mysqli_fetch_assoc($result)){?>	
 
             <tr>
                    <td style="text-align: center;"><?= $i++;?></td>
                    <td id="name"><?= $row['name'];?></td>
                    <td><?= $row['title'];?></td>
                    <td><?= $row['village'];?></td>
                    <td><?= $row['thana_name'];?></td>
                    <td><?= $row['district_name'];?></td>
                    <td><?= $row['mobile'];?></td>
                    <td><?= $row['salary'];?></td>

 <?php               
     
   ?>              
<?php
//echo date_diff(date_create('1992-01-01'), date_create('today'))->y;
 if ($result->num_rows == 0){
 echo '<body style="text-align: center;">
  <div class="col-md-12 text-red" id="pagewidth">
  <h1>No Data Available for Printing!</h1>';
 }}}
   ?>
   </table>  
   <br>
   <br>
   <br>
  </div>
  <div class="control-sidebar-bg"></div>
<script src="../bower_components/jquery/jquery.min.js"></script>
<script src="bower_components/jquery-ui/jquery-ui.min.js"></script>
</body>
</html>
