Empresas
Empleos
  • Sobre nosotros
  • Soluciones
    • Publicación de vacantes
      Publica tu vacante y recibe candidatos calificados en 48h.
    • Evaluación de candidatos
      500+ pruebas técnicas y psicológicas, más anti-fraude.
    • Headhunting
      Búsqueda ejecutiva a la medida de principio a fin.
    • Nómina + EOR
      Dispersión de nómina y EOR en más de 15 países de LATAM.
  • Precios
  • Empleos

0

159
Vistas
select2 placeholder do not show diacritics for French from Localization.resx file

I will appreciate any ideas of how to fix the following problem. In milti-language application I have a page, where I declare a drop-down list to show the list of customers from DB table:

@Html.DropDownListFor(m => m.CustomerId, new SelectList(Model.Customers, "Id", "Name", Model.CustomerId), new { @class = "form-control select2-customer", id = "select2-customer", multiple = "multiple" })

For the DropDownListFor I use select2. select2 is defined in the shared page:

 $(".select2-customer").select2({
        placeholder: '@Localization.SelectCustomer',
        allowClear: true
    });

The value for placeholder comes from the Localization file, where I have a definition for French: https://i.stack.imgur.com/tp9Q3.png

Name: SelectCustomer

Value: Sélectionner un client

Problem: When I run the application and then change language from English to French, text in French in all places (UI, items of drop-down lists, navigation menu, etc.) is ok, but the placeholder is broken: it shows S&#233lectionner un client instead of expected Sélectionner un client

I tried off to wrap the placeholder value with @Html.Raw, HttpUtility.HtmlDecode - it didn't help.

Thanks!

about 4 years ago · Juan Pablo Isaza
Responde la pregunta
Encuentra empleos remotos

¡Descubre la nueva forma de encontrar empleo!

Top de empleos
Top categorías de empleo
Empresas
Publicar vacante Precios Comercial
Legal
Términos y condiciones Política de privacidad
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Recomiéndame algunas ofertas
Necesito ayuda