I use jQuery(ajax) in django, and I want when happen error in django server i get server error instead "the server responded with a status of 500 (INTERNAL SERVER ERROR)"
In fact I want to get django error msg (for example "KeyError or model not found and etc." in ajax function
$.ajax({
...
success:function(json){
...
},
error:function(xhr,errmsg,err){
// this here i want to show django error)
alert(django error msg);
}
});
thanks.