<?
session_start();
include("opendb.php");
include("test.php");
$result=mysqli_query($db,"select * from stock where depot='$cde'");
if(mysqli_num_rows($result)<=0)
{
  print "<body bgcolor=ivory>";
  return;
}
?>
<style>
body{font-family:fixed};
td{font-family:fixed};
</style>
Stock Report of <? print $cde?> as on <? print date("d-M-Y",time())?>
<table border=0 cellspacing=1 cellpadding=1 bgcolor=black width=>
<tr bgcolor='white'><td width=5><center><b>No.</td><td width=350><center><b>Item Name </td><td><center><b>Quantity</td></tr>
<?
 $i=1;
 while($row=mysqli_fetch_row($result))
 {
   print "<tr bgcolor='white'><td>".$i++."</td><td>$row[0]</td><td align=right>$row[2]</td></tr>";
 }
?>
</table>
