Calendar widget translate problem on Drupal 7 I am experiencing issues with the translation of the Date/calendar Widget for Drupal 7 and I wonder if there is a solution for this problem without mixing with the source code for the date/calendar module, or if maybe I am missing some point here.

Here are the initials for the week days in the little calendar in English:

M - Monday
T - Tuesday
W - Wednesday
T - Thursday
F - Friday
S - Saturday
S - Sunday


In Portuguese, the same week days are:

S - Segunda-feira
T - Terça-feira
Q - Quarta-feira
Q - Quinta-feira
S - Sexta-feira
S - Sábado
D - Domingo


The problem is that when I translate the 'T' (Thursday) to 'Q' (corresponding to "Quinta-feira"), both days starting with a 'T' in English are translated as 'Q' in Portuguese. Both Tuesday and Thursday are shown with a 'Q' on top, and that of course is plain wrong for displaying the calendar in Portuguese. 

Is there some built-in localization/translation feature for the calendar that doesn't use the Drupal translation tool that does not seem to work in this case?

Thank you.
If you by date widget means the JS popup, then that part is not actually translatable in Drupal. Instead you need to activate a load a language js file for the jQuery plugin which will translate the widget for you. If those translations are wrong, you should file a bug report with the jQuery team.

I searched the data module and couldn't find the text strings that you mention above. Drupal 7 allows modules when creating translatable strings to provide a context. I see that the date module does that several places:

t($date-&gt;format('F'), array(), array('context' =&gt; 'Long month name', 'langcode' =&gt; $langcode));


Doing this will create an extra translatable strings. An example use would be:

t('Order', array('context' =&gt; 'the order of items');
t('Order', array('context' =&gt; 'an e-commerce order');


The word is the same but the meaning is different, by doing the above it will allow translators to translate the strings differently. If a Drupal module provides the text strings for your widget, they will need to do something similar: fx

 t('T', array('context' =&gt; 'Tuesday');
 t('T', array('context' =&gt; 'Thursday');


If the module haven't done this, your best bet is to submit a patch for the module and explain why they need to do this. This is generally a good practice to do when you create translatable string that aren't unique.