Javascript Escape/UnEscape and C# UrlEncode/UrlDecode, Encode/decode

In Javascript I use following code to get the input of user name:

sUserName=escape($get('ctl00_SampleContent_TextBox_Name').value);

In order to display this string to user using C#, the following code is used:


System.Text.StringBuilder strMessageBody = new StringBuilder();
strMessageBody.Append("Hi ");

strMessageBody.Append(HttpContext.Current.Server.UrlDecode(sUserName));
strMessageBody.Append(":

");
strMessageBody.Append("Thanks for ....");

Comments

Popular posts from this blog

Javascript Hosted on Google Drive Not Working Reliably

How to clear MS SQL Server Database log file on GoDaddy

Xamarin Quickstart