Hi people,
I was wondering if it is possible to use jquery to listen for a specific HTTP code response, and then perform an action when it observes that a specific HTTP status has occurred.


For instance is there a way I could do something like?
$scope.$on(‘HTTP_CODE’, function() {$alert(“CUSTOM HTTP CODE: 777”)}

Context:
I have a ruby on rails application with an angularJS frontend, and I am using the devise CustomFailureApp to return a specific http status.
no comments yet
Be the first to share what you think!
Members
Online

source