I'm using this ajax simple code for refresh a div with mySql result. Work, but it's a correct way? For few connections it's ok but for a lot of connections....?
setInterval(function(){
$.ajax({
type: "GET",
url: "current_number.php",
dataType: 'html',
success: function(data) {
$("#current_number").html(""+data+"");
}
});
}, 500);
thanks