2011-12-30, 21:17:40
I encountered a small problem with the plugin News Manager on the display of dates in French.
Accented characters are not taken into account on a monthly ...
so I slightly modified the function nm_get_date:
the line :
by :
the complete function :
I'm not a php expert, but it solved my problem :-)
Maybe my problem is from an error coding in my theme ?
thank you for your feedback
cordially
benoît
Accented characters are not taken into account on a monthly ...
so I slightly modified the function nm_get_date:
the line :
Code:
setlocale(LC_TIME, $NMLANG);
Code:
setlocale(LC_TIME, $NMLANG.'.utf-8');
the complete function :
Code:
/*******************************************************
* @function nm_get_date
* @param $format date format
* @param $timestamp UNIX timestamp
* @return date formatted according to $NNLANG
*/
function nm_get_date($format, $timestamp) {
global $NMLANG;
$locale = setlocale(LC_TIME, null);
setlocale(LC_TIME, $NMLANG.'.utf-8');
$date = strftime($format, $timestamp);
setlocale(LC_TIME, $locale);
return $date;
}
I'm not a php expert, but it solved my problem :-)
Maybe my problem is from an error coding in my theme ?
thank you for your feedback
cordially
benoît