According to the documentation, there is no special error handler for the $.post method.
What you need to do if you want to have both success and failure handlers is to use the low-level $.ajax method. The documentation can be found here: http://api.jquery.com/jQuery.ajax/
$.ajax({ type: "POST", url: "some.php", success: function(html){ }, error: function(){ } });
source share