C#转换编码

content = System.Web.HttpUtility.UrlEncode(content,System.Text.Encoding.GetEncoding("gb2312"));
下面还有几种转换的方式byte[] 和 string
System.Text.Encoding.GetEncoder("utf-8").GetBytes(str);
System.Text.Encoding.GetEncoder("utf-8").GetString(byte[]);
原文地址:https://www.cnblogs.com/yesun/p/450054.html