Win a copy of Functional Reactive Programming this week in the Other Languages forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

internalisation to hindi language not getting proper display...

 
anildhulipalla kumar
Greenhorn
Posts: 1
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
My code is:

java.lang.Jsp page is


<%@ page language="java" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8"%>
<%@taglib uri="/WEB-INF/struts-bean.tld" prefix="bean" %>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" >
<title>Font Test Interface</title>
</head>
<body>
<table>
<tr>
<td>
Select your language :
<a href="changeLocale.do?method=english">English</a>
<a href="changeLocale.do?method=french">French</a>
<a href="changeLocale.do?method=german">German</a>
<a href="changeLocale.do?method=italian">Italian</a>
<a href="changeLocale.do?method=hindi">Hindi</a>
</td>
</tr>
<tr>
<td>
<bean:message key="label.welcome" />
</td>
</tr>
</table>
</body>
</html>


Action class code is


public ActionForward hindi(ActionMapping mapping, ActionForm form,
HttpServletRequest request, HttpServletResponse response)
throws Exception {
request.setCharacterEncoding("UTF-8");
HttpSession session = request.getSession();
Locale locale = new Locale("hi","in");
session.setAttribute("org.apache.struts.action.LOCALE", locale);
System.out.println("###########hindi");
return mapping.findForward(SUCCESS);
}

i am getting browser but not in hindi format i am putting properties file in utf-8 only still....
please help me .....
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic