c# - Problems with accents on page -
i've asp.net not displaying accents correctly. instead of direção hidráulica\elétrica
i'm getting:direção hidráulica\elétrica
.
i've tried unsuccessfully:
by using html on head tag:
<meta http-equiv="content-type" content="text/html; charset=utf-8" />
by using c#.net:
response.charset = "utf-8";
and on top of .aspx
page:
<%@ page codepage="65001" language="c#" ..
i've no idea how fix this. appreciated. in advance.
the problem here using invalid encoding.
convert text html entities
you can use utf-8 in html converting characters html entities. online converter located here: http://konieczny.be/unicode.html
this resulting string (remove spaces between &, stackoverflow automatically converts it):
dire& #231;& #227;o hidr& #225;ulica\el& #233;trica
save file utf-8
the reason why getting strange characters because saving file ansi. assuming using notepad, go file -> save as. @ bottom find "text encoding". change utf-8.
this available in editor using. if use "charset=utf-8" in html tags, won't change how saved.
Comments
Post a Comment