开发者

HttpUtility.HtmlDecode not decoding spaces?

开发者 https://www.devze.com 2023-02-21 10:17 出处:网络
I have this string test =HttpUtility.HtmlDecode(\"http://test.com/Folder1/Folder2/my%20view.aspx\"); When I look into test it still has %20 instead of a space. Wh开发者_运维知识库y is it not decod

I have this

 string test =  HttpUtility.HtmlDecode("http://test.com/Folder1/Folder2/my%20view.aspx");

When I look into test it still has %20 instead of a space. Wh开发者_运维知识库y is it not decoding this?


You are looking for HttpUtility.UrlDecode() (in the System.Web namespace, I think)


HttpUtility.HtmlDecode not decoding "%20", use HttpUtility.UrlDecode to decode "%20"

0

精彩评论

暂无评论...
验证码 换一张
取 消

关注公众号