Reputation: 38432
What data do I need to send from my server (PHP) so that jQuery recognizes it as error and executes the error callback?
Upvotes: 1
Views: 77
Reputation: 4394
You could send any of the 5xx Server Error codes listed here back in your HTTP header. http://en.wikipedia.org/wiki/List_of_HTTP_status_codes
Or else, you could just send back a message that states an error has occurred in the response, then check for that string on the client and handle that...
Upvotes: 0