Hello!
Can anybody point me towards which steps are necessary to display a 12-hours timeformat including AM and PM in a non-english language.
Thanks a lot,
Christoph
Hello!
Can anybody point me towards which steps are necessary to display a 12-hours timeformat including AM and PM in a non-english language.
Thanks a lot,
Christoph
Hi Christoph,
Its set by the language pack - you'd have to identify the strings and edit.
regards,
George.
I know there are time-format strings in the language-pack, as in days, hours and minutes, but how do i handle it concerning the logic of whether itis AM or PM ?
Hi Christoph,
If you have a look in langconfig.php (for example):
$string['alphabet'] = 'A,Ä,B,C,D,E,F,G,H,I,J,K,L,M,N,O,Ö,P,Q,R,S,T,U,Ü,V,W,X,Y,Z';
$string['backupnameformat'] = '%Y%m%d-%H%M';
$string['datepickerplaceholder'] = 'tt/mm/jj';
$string['decsep'] = ',';
$string['firstdayofweek'] = '1';
$string['iso6391'] = 'de';
$string['iso6392'] = 'ger';
$string['labelsep'] = ': ';
$string['listsep'] = ';';
$string['locale'] = 'de_DE.UTF-8';
$string['localewin'] = 'German_Germany.1252';
$string['localewincharset'] = 'WINDOWS-1252';
$string['oldcharset'] = 'ISO-8859-1';
$string['parentlanguage'] = '';
$string['strfdateattime'] = '%d %b %Y um %H:%M';
$string['strfdateshortmonth'] = '%d %b %Y';
$string['strftimedate'] = '%d. %B %Y';
$string['strftimedatefullshort'] = '%d.%m.%y';
$string['strftimedateseconds'] = '%d %b %Y um %H:%M:%S';
$string['strftimedateshort'] = '%d. %B';
$string['strftimedatetime'] = '%d. %B %Y, %H:%M';
$string['strftimedatetimeshort'] = '%d.%m.%Y %H:%M';
$string['strftimedaydate'] = '%A, %d. %B %Y';
$string['strftimedaydatetime'] = '%A, %d. %B %Y, %H:%M';
$string['strftimedayshort'] = '%A, %d. %B';
$string['strftimedaytime'] = '%a, %H:%M';
$string['strftimemonthyear'] = '%B %Y';
$string['strftimerecent'] = '%d. %b, %H:%M';
$string['strftimerecentfull'] = '%a, %d. %b %Y, %H:%M';
$string['strftimeshort'] = '%H:%M';
$string['strftimetime'] = '%H:%M';
$string['thischarset'] = 'UTF-8';
$string['thisdirection'] = 'ltr';
$string['thisdirectionvertical'] = 'btt';
$string['thislanguage'] = 'Deutsch';
$string['thislanguageint'] = 'German';
$string['thousandssep'] = '.';
Any changes here will affect all the users using the language pack.
cheers,
George.
So here is what i tried up to now:
I changed the string 'sessiondatetimeformat' in different way to observe its effects.
f.e. when altering it in the english language-pack and removing the '%p' from '%I:%M %p', the AM/PM was removed as expected from the output in the english locale.
But even when i copied the string identically into my german language-file, the AM and PM was not displayed.
Looking up the php-function strftime (http://php.net/manual/en/function.strftime.php), i saw that it supposedly removd the AM/PM when it detected certain non-english locales. So i tried placing setlocale(LC_TIME, 'en_US');, both at the beginning of the function that outputs the sessions including their respective start- and endtime, or the renderer.php. Neither had any effect on the output.
Could anybody help me further with this problem?