Can anyone post a sample code wherein theres a running timer(javascript settimeout) and doing data retrieval..
basically what i this timer does is to display new messages..
myFunction(param){
//data retrieval operation
//using getJSON.. call displaydata() base on param
settimeout("myFunction()", param, 1000);
}
function displaydata(param){
//processing
alert('test')}
Should i use getJSON? i think theres a problem with the assynchronous call..