• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Tim Cooke
  • Ron McLeod
  • Jeanne Boyarsky
  • Paul Clapham
Sheriffs:
  • Liutauras Vilda
  • Henry Wong
  • Devaka Cooray
Saloon Keepers:
  • Tim Moores
  • Stephan van Hulst
  • Tim Holloway
  • Al Hobbs
  • Carey Brown
Bartenders:
  • Piet Souris
  • Mikalai Zaikin
  • Himai Minh

Need to get utf-8 strings in java servlet

 
Greenhorn
Posts: 3
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator


Hai,

Im facing a problem when i try to get utf-8 string in java servlet.

I have a jsp page where i have set



Im trying to enter subject name in tamil and english (both langauges)

In my servlet i have coded




but when i try to print those values im able to print value of englishname
when trying to print tamil name im getting blablabla values

i need to store subject name in both language tamil and english into my database SQL server
i have declared the datatype as nvarchar(max) which stores unicode characters

can anybody help me to sort it out?

Thanks


 
Bartender
Posts: 1210
25
Android Python PHP C++ Java Linux
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
If you're seeing garbled characters in console, it doesn't mean the parameter values are wrong - console has problems with displaying other languages since it can't find the glyphs. Log the values to web server log file or your own log file, open it with Notepad++ and select UTF-8 encoding. If you see non-English characters correctly, your app is working fine.
 
Sheriff
Posts: 67650
173
Mac Mac OS X IntelliJ IDE jQuery TypeScript Java iOS
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
"gk ven", please check your private messages for an important administrative matter.
 
venkat gopal
Greenhorn
Posts: 3
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Hai,

When i print utf-8 values im facing a problem - the values of ¯Œ (BOM) symbol gets replaced by ? mark.
What is the reason for values getting replaced? What should be done to avoid such replacement?

Can anybody provide me a solution?


Thanks
 
reply
    Bookmark Topic Watch Topic
  • New Topic