UpdatePanel seems to re-encode characters in the page title? UpdatePanel seems to re-encode characters in the page title? asp.net asp.net

UpdatePanel seems to re-encode characters in the page title?


In your code to set the page title, wrap the text in Server.HtmlDecode:

Page.Title = Server.HtmlDecode("Exchange ‘07 Groups")


I had the same situation with the SM (service mark, as opposed to TM for trademark) which we did setting the page title with Page.Title = "My Company &#8480"; . It reencoded it upon postback.

What we did is in the page head we statically added it< title >My Company &#8480;< /title >

Worked like a charm.


The reason it displays it incorrectly is because .Net is attempting to be safe and HTML encode the title (for prevention of the multiple types of attacks that are possible).

In ASP.Net MVC, you can now use the Html.Raw() method. As far as straight ASP.net, I don't know what the method would be.