This problem lead me to learn a new thing which I thought may helpful programmers in many cases.
I used java script escape funnction to encode html contents which I need to decode on the server side.
The regualr methods we have on C# to handle escaping/unescaping are:
- Microsoft.JScript.GlobalObject.unescape(string escapedString)
- Server.UrlDecode(Microsoft.JScript.GlobalObject.unescape(string escapedString))
To use it in your code: Reference Micrtosoft.JScript.dll in your project.
Use the static methods in GlobalObject to do the escape/unescape
Thanks for Reading..