Originally posted by Stuart Ash:
If you textbox at the time of submission displays only the final chinese characters, then Java basically represents each one of these characters as a single char (of some unicode value up in the chinese region.) Thus, a simple, str.length() should work
Stuart,
yes my textarea would be displaying the final chinese characters only at the time of form submittal. I have one doubt, these simplified chinese characters takes more space as compared to english ie some of them takes 2 bytes some 3 bytes. Also when I write these charcters on my text area i am able to write about 30 characters on a avergae per line.
So does it mean that I have to increase the rows and cols of the text area as the upper limit should be same as that of english character. I just wanted to understand is this the approach being followed in other chinese sites also. As a matter of fact, I looked at yahoo china, but there the look and feel is almost the same as yahoo india or yahoo US.
Does u have any idea how can I validate the chinese character in javascript, let's say I do not want the chinese equivalent of ; and ! not to be entered by the user. how can this be achieved ?
I hope I haven't confused you..
Thanks
Shalu