Tag

window.interval

w

Ajax call request in jquery

Making an ajax call using jquery is pretty simple, let’s create an ajax request that updates a specified contents every 20 seconds!
$.ajax({
url : 'YOUR URL WOULD GO HERE',
type : 'GET',
data : {
'parameter' : 10
},
dataType:'json',
success : function(data) {
console.log('Data: '+data);
},
error : function(request,error)
{
console.log("Request: "+JSON.stringify(request));
}
});

Latest from Sarabpreet