<?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;}
  @font-face {
  font-family: 'Bangla';
  src: url('../../dist/fonts/SutonnyOMJ.ttf');
  font-weight: normal;
  font-style: normal;
}
.bangla{
  font-family: bangla;
  text-align: center;
  src: url(../../dist/fonts/SutonnyMJ.ttf);

}
#sl{text-align: center;font-size: 20px; width: 10%;   font-family: bangla;}

#date{position: absolute; right: 209px; position: absolute; top: 79px;}
.print-area{width:850px; height:1050px; margin:auto; box-sizing:border-box; }
.header,.print-area{text-align: center;}
.header h1 {margin:0px; padding:0px; font-size: 35px;  font-family: 'Bangla';}
.header h3 {margin:0px; padding:0px; font-size: 25px;  font-family: 'Bangla';}
.header h2 {margin:0px; padding:0px; font-size: 20px;  font-family: 'Bangla';}
#heding {font-size: 30px; margin:0; text-align: center;}
#center_font {  font-family: 'Bangla'; text-align: center;}
#name {font-family: 'Bangla'; text-align: left; width: 20%px;}
#title {font-family: 'Bangla'; text-align: center; width:15%px;}
#thana_name {font-family: 'Bangla'; text-align: center; width: 15%px;}
#district_name {font-family: 'Bangla'; text-align: center; width: 15%px;}
#mobile {font-family: 'bangla'; text-align: center; width: 15%px;}
#salary {font-family: bangla; text-align: center; width: 15%px;}

th, td {  font-size: 20px;   font-family: 'Bangla';}

#pic_log { position: absolute;top: 10px;left: 10px; width: 100px;}


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>
  <div style="max-width:320px; height: 2px;"><img src="../logo/logo.png" alt="logo" id="pic_log" style="margin-top: px;"/></div>                
<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>
        <th style="text-align: center;">বেতন</th>
      </tr>
  </thead>
			
<?php
$i=1;
   $staff_division=mysqli_query($con,"SELECT distinct * FROM `teacher_view`

  WHERE  status=1 AND staff_position=2  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='9' 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 staff_position=2 AND teacher_view.status=1  order by teacher_sr asc");
     while($row = mysqli_fetch_assoc($result)){?>	
  <tbody>
    <tr>
      <td id="sl"><?= $i++;?></td>
      <td id="sl"><?= $row['teacher_id'];?></td>
      <td id="name">&nbsp;<?= $row['name'];?></td>
      <td id="title"><?= $row['title'];?></td>
      <td id="title"><?= $row['village'];?></td>
      <td id="thana_name"><?= $row['thana_name'];?></td>
      <td id="district_name"><?= $row['district_name'];?></td>
      <td id="mobile"><?= $row['mobile'];?></td>
      <td id="salary"><?= $row['salary'];?></td> 
    </tr>  
  </tbody>             
             
<?php
 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>
