Unicode characters encoding issues

This topic was automatically closed 365 days after the last reply. New replies are no longer allowed.
Il y a 10 ans
Hi gurus,

we have problems with the non-Asci characters encoding. Some characters are encoded as html characters e.g. insted of char é, we get é.

Is there a way how to configure encoding based on the culture/code page etc.?

Thanks.
Il y a 10 ans
Hi, I have the same problem. I am using NopCommerce 3.0 and when I enter to title "Vybavení Čistých Prostor" Output is Vybavení Čistých Prostor
I searched in file but it´s in utf-8 and charset of page also utf-8. In database it´s OK, so where is the problem?
I tried enter the text as static text on page but output is almost same (VybavenĂ­ ÄŚistĂ˝ch Prostor) so in database should´nt be problem.
Can somebody help me?
Il y a 8 ans
This is my solution and it work

@helper FormatUnicode(HtmlString htmlString)
{
    var input = htmlString.ToString();
    input = input.Replace("ê", "ê");
    input = input.Replace("ô", "ô");
    input = input.Replace("â", "â");
    input = input.Replace("á", "á");
    input = input.Replace("à", "à");
    input = input.Replace("ã", "ã");
    input = input.Replace("í", "í");
    input = input.Replace("ì", "ì");
    input = input.Replace("ý", "ý");
    input = input.Replace("ê", "ê");
    @Html.Raw(input)
}

<title>@FormatUnicode(Html.NopTitle(true))</title>
Il y a 2 ans
The only way to resolve this was by adding text encoding settings in NopEngine => ConfigureServices

services.Configure<WebEncoderOptions>(options =>
            {
                options.TextEncoderSettings = new TextEncoderSettings(UnicodeRanges.All);
            });
This topic was automatically closed 365 days after the last reply. New replies are no longer allowed.