This code read the pms, that is stored inside a php file and print them on the screen every 0.01 second to be in realtime or work dynamic, but i’m using a “CSS Emoticons plugin”, it works and show the emoticons, but i can’t use the animate one or i can, but it would not finish, it would restart every 0.01 second unless i turn it off. I want to use it with the dynamic text, but i dont know how. Please help me out guys
function updateStats(stat) {
var stat = ["MSG", "NAME"];
var url = "POST.php";
$.each(stat, function (i, key) {
$.post(url, {
stats: key
}, function (data) {
$("#" + key).html(data);
$('div.icon').emoticonize({
//delay: 800,
//animate: false
});
});
});
}
setInterval(function () {
updateStats("updateStats");
}, 10);
Try with this…