public static class HttpExtension { public static string HtmlEncode(this string data) { return HttpUtility.HtmlEncode(data); } public static string HtmlDecode(this string data) { return HttpUtility.HtmlDecode(data); } public static NameValueCollection ParseQueryString(this string query) { return HttpUtility.ParseQueryString(query); } public static string UrlEncode(this string url) { return HttpUtility.UrlEncode(url); } public static string UrlDecode(this string url) { return HttpUtility.UrlDecode(url); } public static string UrlPathEncode(this string url) { return HttpUtility.UrlPathEncode(url); } }
Monday, January 30, 2012
Best Extension Methods: HTTP Extension Methods
Best Http Extension Methods
Share This!
Labels:
C#.NET,
Extension Methods
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment