Hello! I need a callback to be executed, when any ajax request begins. I used this code:
var cnt=0; $('*').ajaxSend(function() { cnt++; }); function Teszt() { $.post('jquerytest.php'); alert(cnt); } When i call function Teszt(), the alert shows '6'. Why?