Last post Aug 05, 2011 12:11 AM by KhD
Aug 04, 2011 05:11 AM|KhD|LINK
I have developed a web application to upload and download files. Filename and file information are stored in database. Also, these files and other file information are displayed in a gridview. The website is localized for Chinese and Japanese languages.
I want the users to be able to enter Chinese and Japanese filenames as well. In Web.config file, I have entered this
<globalization requestEncoding="utf-8" responseEncoding="utf-8" fileEncoding="utf-8"/>
How can this be done? I read in some forums that Server.UrlEncode can be the solution, but how to use this in the application?
Also, which encoding will be the best for this?
Aug 04, 2011 05:34 AM|manishgvsharma2000|LINK
See this article
Aug 05, 2011 12:11 AM|KhD|LINK
I had thought this would be more complicated than this. But adding the above line in web.config and using nvarchar as the datatype for all the parameters in queries, it works!