c# - Replace ASCII characters with their equivalent -
I am setting a value in the cookie using cookies and receiving the contents of the cookie in the back code.
But the problem is that I am storing the string with some special characters or white space characters, when I am retrieving the contents of the cookie, converting special symbols into ASCII equivalents are given.
For example, if I want to store in the How do I get it? help please. Use: / P> The built-in function that can be used by other options which you can use in .NET Framwework (see below). If necessary, you can specify an encoding. or: See the documentation for some alerts. Adam - (SET) cookie, then it will be
Adam% 20-% 20% 28SET% 29 I am getting converted and archived and when I am recovering it, I get the same
Adam% 20-% 20% 28SET% 29 . But I can get this code under the code
in
C #
string is decoded = HTTTY. Urlcode (encoded string);
string is decoded = URI.UnescapeDataString (s);
javascript
var decoded = decodeurIComponent (s) in
; Before jumping on using
unescape as suggested in other queries, read. You may also want to read.
Comments
Post a Comment