Is it possible to add some additional parameters to get/post methods in jQuery .
Ex :
$.get(url,{a:b,c:d},function(data){
//codes..
});
Here you can see that it contains two parameters, a and c.
Now think i need to add an additional parameter [e:f] to every get/post methods in a web page.
is this possible ?
So when we trigger a get/post method it need automatically add a additional parameter .
Thank you .
You can use
jQuery.ajaxSetup()to set defaults.However, you should be aware that these parameters will not be included if you use
.load(), due to what is most likely a bug in jQuery.