我试过了:
string decodedHtml = HttpUtility.HtmlDecode(html);
其中 html 是编码后的 html。似乎这根本不会改变字符串。 html 仍然是编码的。
最佳答案
string s = System.Uri.UnescapeDataString(html);
关于c# - 如何解码使用 encodeURIComponent() 在 JS 中编码的 HTML?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/6022832/