accessing the jquery function after success call?

\[code\] jQuery(function ($) { /* fetch elements and stop form event */ $("form.follow-form").submit(function (e) { /* stop event */ e.preventDefault(); /* "on request" */ $(this).find('i').addClass('active'); /* send ajax request */ $.post('listen.php', { followID: $(this).find('input').val() }, function () { /* find and hide button, create element */ $(e.currentTarget) .find('button').hide() .after('<span class="following"><span></span>Following!</span>'); }); }); });\[/code\]i want to know what when i process the mysql query in the listen.php file, how deos it get the success message back, and then perform the change after?
 
Back
Top