<?php
error_reporting(0);
ob_start();
session_start();
include_once("include/dbconnect.php");
$update=mysqli_query($conn, "select * from customer_orders where confirm_status='Accepted' and order_status=1");
$update1=mysqli_fetch_array($update);
$ttt = mysqli_num_rows($update);
?>
<a href="all_orders.php" style="color:red;font-size:18px; font-weight:bold"><img src="https://www.crpfpublicschool.com/images/flash.gif"><?php echo $ttt;echo "&nbsp;"; echo "Orders"; ?></a>
<?php
if ($ttt > 0) {
                              echo '<script type="text/javascript">
                                $(document).ready(function() {
                                    $("button[name=notify]").click();
                                });
                            </script>';   }  
?>
    <?php  
if($ttt>0){
        ?>
    <script>
     $(window).load(function(){        
   $('#myModal').modal('show');
    }); 
</script>
<audio autoplay loop>
      <source src="notification.mp3">
</audio> 
<?php } ?>