Russian text not displaying in DataTable
Russian text not displaying in DataTable
Hi,
I am using server side jquery DataTable to show the list of data. there is some Russian (Cyrillic) data in the list.We are getting data through database and put it into JSONObject and this object is taken by DataTable BUT I am getting ??? ???? in place of Russian Character.
At Jsp page, I used
<%@page contentType="text/html; charset=UTF-8" %>
IN Controller, I used
@RequestMapping(value = "view/{list}", method = RequestMethod.POST, produces={"application/json; charset=UTF-8","/;charset=UTF-8"})
public void getList(ModelMap model, @RequestParam String showAll, HttpServletRequest request, HttpServletResponse response) throws IOException, JSONException {
JSONObject result = new JSONObject();
PrintWriter out = response.getWriter();
try {
.......................................
........................................
...........................................
..............................................
result = (JSONObject) abcDao.getList();
response.setContentType("application/json");
response.setHeader("Cache-Control", "no-store");
response.setCharacterEncoding("UTF-8");
out.print(result);
model.put("result", result);
} catch (Exception e) {
logger.error("", e);
}
}
Please help me out where I am wrong
Regards,
Rama Shankar