Just made our ProgramIt supports Chinese characters. I will post the first article here
To put it bluntly, it is actually very simple, but it is still a detour. Write down and hope to be useful.
1. Web. config: Set the original
<Globalization requestencoding = "UTF-8" responseencoding = "UTF-8"/>
Change
<Globalization requestencoding = "gb2312" responseencoding = "gb2312" fileencoding = "gb2312"/>
2. there is no way to change the existing SQL Server database. You can only create a new database, and then change collation name to XXX next to chinese_prc_xxx. Bin is binary, CI = case insensitive, AI = accent insensitive, ks = Kana sensitive, Ws = width sensitive, I use ci_ai
3. The original database must be retrieved, but cannot be backed up/restore. Otherwise, collation will be changed. You can only use import/export.
4. I almost forgot to talk about it. All fields that want to store Chinese characters must change varchar to nvarchar (twice the occupied space)
The above said take a detour is because, when SQL Server has not changed, the requestencoding into ISO-8859-1 can also be supported, but every time you have to change encoding for Chinese, it is useless even if contenttype is set on the page. Because the HTTP header returned by the server already specifies Encoding As a iso-8859-1.