private boolean isAjaxRequest(HttpServletRequest request,HttpServletResponse response){
if(request.getHeader("x-requested-with") != null
&&request.getHeader("x-requested-with").equalsIgnoreCase("XMLHttpRequest")){
return true;
}else{
return false;
}
}