[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
reading chinese and other languages from a jsp page.
At the moment what i am trying to do is something quite simple. In my form page
I am entering some chinese text (by doing cut and paste from a chinese word
doc.) clicking on submit and printing the field value to the console using
System.out.println. the printed string is converted to UTF-8 Unicode (looks
like 帕&#20811...). excuse me if i am using the wrong terminology.
what i would like to do is capture the input as is. and print it as is. i
understand that it will end up printing funny characters on the console. what i
have tried to do so far is.
request.setCharacterEncoding("GBK");
item = new String(request.getParameter("input").getBytes"GBK"), "GBK");
System.out.println(item);
My ultimate goal is to create any html page with say Big5 encoding. and i want
to store the chinese characters as is.
help needed asap. thanks.
=====
Poorav Chaudhari
__________________________________________________
Do You Yahoo!?
Yahoo! Health - Feel better, live better
http://health.yahoo.com