<html>
<body>
<head>
<script> window.onload = function(){ navigator.vibrate([500]); } </script>
<?php
error_reporting(0);
//$conn = odbc_connect('DRIVER={SQL Server};SERVER=POSNET,1433;DATABASE=POSNET','sa','3641a3641');
include "veritabani.php";
@session_start();
ob_start();
$kul_id = $_SESSION["id"];
$kul_adi = $_SESSION["name"];
date_default_timezone_set('Europe/Istanbul');
$bugun = date("Y-m-d");

$ona =odbc_exec($conn," 
  
     select magazalar.magazaadi , ISNULL( SUM(tutar),0) ciro , ISNULL( SUM(case c.belgetipi when  'GPS' THEN 0 ELSE c.belgeadeti end),0) adet from (select kasano , magazaadi from MAGAZAKASA )as magazalar left join CIRO as c 
on c.kasano = magazalar.kasano and c.iptalmi=0  where tarih > '$bugun'
group by magazalar.magazaadi  
  ");
  
   while($kay=odbc_fetch_array($ona))
	{	
  

  $say += $kay["adet"];

  


  }


?>



<?php echo "<font size=4  ><div class='animated flip'>$say </div></font>";

	?>
</head>
</body>
</html>
