Hi all,
I am sending some "chinese" data through form post from
jsp file to some
servlet.
This as fine I an sending proper UTF8 enconing formant.
But my problem is in the servlet how can I fetch this form data and save it to text file on my file system.
when I am saving it to file system it is saved as some junk characters.
this is the jsp file I am using for sending data.
<%@ page language="java" contentType="text/html;charset=UTF-8" pageEncoding="UTF-8" %>
<%@ page import="java.net.URLDecoder" %>
<%@ page import="java.net.URLEncoder" %>
<HTML>
<HEAD>
<TITLE>My Interface</TITLE>
<meta http-equiv="Content-Type" content="text/html; charset=TH">
<meta http-equiv="Content-Type" content="text/html; charset=tis-620">
<meta http-equiv="Content-Type" content="text/html; charset=window-874">
</HEAD>
<BODY>
<form action="my servlet adress." method="post" >
<INPUT type="text" name="rword" maxlength="60">
<INPUT type="Submit" VALUE="Submit">
</form>
</BODY>
</HTML>
can u please help me how to fetch this chinese charater in servlet and save to text file so that it will look in proper format.
looking for ur response
Thanks and regards
sunil