I still don't get why SMF and Wedge don't just have the months set appropriately for language and use them rather than trying to mess around with ucwords...
SMF bug 4870 (incorrectly capitalised month names)
« le 29 Février 2012 à 14:56 »
Ce sujet a été marqué résolu par son auteur, le 7 Octobre 2012 à 17:46
if ($user_info['setlocale'])
{
foreach (array('%a', '%A', '%b', '%B') as $token)
if (strpos($str, $token) !== false)
$str = str_replace($token, !empty($txt['lang_capitalize_dates']) ? westr::ucwords(strftime($token, $time)) : strftime($token, $time), $str);
}
else
{
// Do-it-yourself time localization. Fun.
foreach (array('%a' => 'days_short', '%A' => 'days', '%b' => 'months_short', '%B' => 'months') as $token => $text_label)
if (strpos($str, $token) !== false)
$str = str_replace($token, $txt[$text_label][(int) strftime($token === '%a' || $token === '%A' ? '%w' : '%m', $time)], $str);
}