<style>
.myh1{
  font-size:16px;
  font-family:Arial;
}
.myh2{
  font-size:14px;
  font-family:Arial;
  font-weight:100;
}
.td1{
  padding-left: 10px;
}
.ipt1{
font-family:Arial;
font-size:12px;
text-align:center;
}
.lsttable{
font-family:Arial;
border-collapse:collapse;
margin: 5px 5px 5px 5px ;
}
.div_desc{
margin: 10px 10px 10px 10px;
font-family:Arial;
font-style:italic;
font-size:12px;
text-align:left;
width:600px;
}
    
  .rpt_tbl{
  font-family:Arial;
  font-size:14px;
  width:700px;
    
  }
</style>

<?
$numpgbk = $_POST["npgbk"];
$tdate = $datefrom;
?>

<?
  if($rmk!=="a"){
    //$ttitle = " - " . $arrEvent[$rmk];
      $strCatatan = strtoupper($arrEvent[$rmk]);
  }else{
    //$ttitle = "";
      $strCatatan = "SEMUA CATATAN";
  }

  if($teaid!=="a"){
      $strTea = strtoupper($arrTea[$strTea]);
  }else{
      $strTea = "SEMUA STAF";
  }
?>

<center>
    
<div style=" page-break-after:always">      
      
<table width="800px" border="0">
<tr>
  <th rowspan="2">
    <img src="img/<?= $mysys->imgPath ?>" height="50px" />
  </th>
  <th class="myh1">LAPORAN CATATAN <?= strtoupper($mysys->schName)  ?>
  </th>
</tr>
<tr>
  <th colspan="2" class="myh1">
      CATATAN : <u><?= $strCatatan ?></u> 
      &nbsp;&nbsp;&nbsp;STAF: <u><?= $strTea ?></u><br>
      TARIKH : <u><?= convertDateFor($datefrom) ?> ~ <?= convertDateFor($datetil) ?></u></th>
</tr>
</table>
      
<hr width="800px" />
      
  <table class="lsttable" width="800px"  border="1">
	<tr>
      <th width="20px">&nbsp;</th>
	  <th>NAME</th>
	  <th>DATE</th>
	  <th>NOTICE</th>
	</tr>
	
  <?
    $i=1;
	$ii=1;
	$iii=3;
    foreach($arrRcd as $tteaid=>$arrRcd2){
	?>
	<tr>
	  <td style="padding-left: 5px"><?= $i ?></td>
	  <td valign="top" rowspan="<?= count($arrRcd2) ?>" style="padding-left: 5px"><?= $arrTea[$tteaid] ?></td>
	<?
	  foreach($arrRcd2 as $tdate=>$tarrrcd){

        if($ii>1){
          echo "<tr><td></td>";
        }
		
		if($tarrrcd["notice"]!=""){
		  $tnotice2 = $arrEvent[$tarrrcd["event"]] . " - " . $tarrrcd["notice"];
		}else{
		  $tnotice2 = $arrEvent[$tarrrcd["event"]];
		}
	  ?>
	  <td style="width: 100px; text-align: center"><?= convertDateFor($tdate) ?></td>
	  <td style="padding-left: 5px; width: 400px; font-size: 11px">&nbsp;<?= $tnotice2 ?></td>
	  </tr>
	  <?
	    $ii++;
        $iii++;
		?>
	  <?
	  }
	?>
	</tr>
	<?
	  $i++;
	  $ii=1;
	}
  ?>
  </table>
  </div>
</center>