一个aspx页面有utf-8编码

如何更改一个aspx页面以进行utf-8编码?

我的web.config有以下代码:

   

试过这个:

 meta http-equiv="Content-Type" content="text/html; charset=UTF-8" 

不起作用。

试试这个;

      

要设置单个页面的编码,请设置RequestEncoding指令的RequestEncodingResponseEncoding属性:

 <%@ Page RequestEncoding="utf-8" ResponseEncoding="utf-8" %> 

或者你可以使用这样的location

      

阅读更多: 如何:为ASP.NET网页全球化选择编码。

尝试插入

 Response.ContentEncoding = System.Text.Encoding.UTF8; 

如果你想动态地在你的Page_Load中。