Start Building Professional
Web Apps Today


 
Categories Question details Back To List
Question  posted by Craig Efrein on Jan 19, 2009 04:35
open dhtmlx forum
Calendar in Grid + Special Characters

Hello,

I have figured out using dhtmlxCalendarLangModules, how to add other languages to the calendar. I am having trouble however with months that have accents.

I have my array
monthesFNames: ["Janvier", "Février", "Mars", "Avril", "Mai", "Juin", "Juillet", "Aout", "Septembre", "Octobre", "Novembre", "Decembre"],

When the calendar comes up, Fevrier appears with a question mark where the é should be. F?vrier.

In your example for German, the month of March has an accent and comes up fine
http://dhtmlx.com/docs/products/dhtmlxCalendar/samples/initialization/calendar_lang.html?un=1226331130000
monthesFNames: ["Januar", "Februar", "März", "April", "Mai", "Juni", "Juli", "August", "September", "Oktober", "November", "Dezember"],

Can you tell me what I am doing wrong?

Thanks,
Craig

Answer posted by Support on Jan 19, 2009 06:04
Please be sure that  both script and page uses the same text encoding ( text encoding for script can be specified for related attribute 
Such error as in your case, occurs when there is no char in font for some text. Most common issue - loading iso-8859-1 text on UTF page. 

Answer posted by Craig Efrein on Jan 19, 2009 06:26
I'm not sure I understand what you mean.   The definitions for each month are being stored directly in the dhtmlxgrid_excell_dhxcalendar.js script in the array monthesFNames.   Since everything is being defined in javascript, I'm not loading any pages. 

Here is my array, stored directly in dhtmlxgrid_excell_dhxcalendar.js
dhtmlxCalendarLangModules['fr'] = {
    langname:    'de',
    dateformat:    '%d.%m.%Y',
    monthesFNames:    ["Janvier", "Février", "Mars", "Avril", "Mai", "Juin", "Juillet", "Août", "Septembre", "Octobre", "Novembre", "Décembre"],
    monthesSNames:    ["Jan", "Fev", "Mar", "Avr", "Mai", "Juin", "Jui", "Aout", "Sep", "Oct", "Nov", "Dec"],
    daysFNames:    ["Dimanche", "Lundi", "Mardi", "Mercredi", "Jeudi", "Vendredi", "Samedi"],
    daysSNames:    ["Di", "Lu", "Ma", "Me", "Je", "Ve", "Sa"],
    weekend:    [0, 6],
    weekstart:    1,
    msgClose:     "Fermer",
    msgMinimize: "Minimizer",
    msgToday:     "Aujourd'hui"
}
Answer posted by Support on Jan 19, 2009 06:31
Please check attached sample. 
Attachments (1)