1$sql = "update tbl_noti set status = 'read'";
2 $result = $conn->query($sql);
3 $row = $result->fetch_assoc();
4 $count = $result->num_rows;
5 echo $count;
6 $conn->close();
7
1<script type="text/javascript">
2
3$(document).ready(function(){
4$("#datacount").load("select.php");
5setInterval(function(){
6$("#datacount").load('select.php')
7}, 20000);
8 });
9
10</script>
11
1$sql = "update tbl_noti set status = 'read'";
2 $result = $conn->query($sql);
3 $row = $result->fetch_assoc();
4 $count = $result->num_rows;
5 echo $count;
6 $conn->close();