<?php 
  $resulttz2 = mysql_query("SELECT * FROM add_teachers where sr_no='$en' and session='$session' and code='$code'");
 $d_salary2=mysql_result($resulttz2,$i,"d_salary");
 echo $d_salary2;
 
?>/
<?php 
$resulta2 = mysql_query("SELECT * FROM salary where sr_no=$en and MAY='Paid' and session='$session' and code='$code' ORDER BY id ");
$qty2x= 0;
while ($a_rowa2 = mysql_fetch_row ($resulta2)) {
?><?php $MAY=$a_rowa2[19];?>
<?php 
$tfee2=$a_rowa2[27];
$qty2x+=$tfee2;
}
echo $qty2x;
$gtfee2+=$qty2x;
$gfees2+=$d_salary2-$qty2x;
?>


 