1770 Posts in 495 Topics by 531 members
Blog Module
SilverStripe Forums » Blog Module » Date Field in Blog Module
Discuss the Blog Module.
Moderators: martimiz, Howard, Sean, Ryan M., biapar, Willr, Ingo, swaiba, simon_w
| Go to End | Next > | |
| Author | Topic: | 5332 Views |
-
Date Field in Blog Module

25 March 2009 at 8:30pm Last edited: 25 March 2009 8:57pm
Hello hou can i change the language from the Month Field not --- March---- change to --- März--- and also Tag Cloud and
Browse by Date --- Thanks
--- Stooni
these i have in mysite/_config.php integratet
i18n::enable();
i18n::set_locale('de_DE');When i give these i18n::set_default_lang('de');
then!
Website Error
There has been an errorThe website server has not been able to respond to your request.
-
Re: Date Field in Blog Module

26 March 2009 at 4:34am
Write this to set German language in the _config.php
i18n::set_locale('de_DE');
setlocale (LC_ALL, 'de_DE@euro', 'de_DE', 'de', 'ge');But you have to write a Function to use the PHP Date like %B für "März".
-
Re: Date Field in Blog Module

31 March 2009 at 3:44am
thanks first!
You can helb mie to write this i am not found these function!
thanks
---stooni
-
Re: Date Field in Blog Module

31 March 2009 at 5:14am Last edited: 31 March 2009 5:34am
Free format date strings in the templates:
$Date.FormatI18N(%e %B %Y %R)
Apart from the changes in mysite/_config.php, you could add this to FormatI18N(), so it does setlocale() by itself:
setlocale(LC_TIME, i18n::get_locale() . ".utf8");
-
Re: Date Field in Blog Module

31 March 2009 at 8:00pm
ok super thanks very much !!!!
First
i18n::set_locale('de_DE');
setlocale(LC_TIME, i18n::get_locale() . ".utf8");then in the templates rewrite format date
$Date.FormatI18N(%e %B %Y %R) or $Date.FormatI18N(%e %B %Y) (without time!!)Thanks !!!!!!
---- some stones falling form my......----stooni
-
Re: Date Field in Blog Module

22 April 2009 at 11:27am
Hi!
Please stooni, could you say me what SS version are you using? Here, with 2.3.1, where i18n of pages has been somehow removed, I'm not able to use FormatI8N with dates. Maybe it's unrelated.
Best regards,
Juan -
Re: Date Field in Blog Module

22 April 2009 at 6:01pm
i use Version SST 2.3.1 with the template andreas02 these is the url :
http://stalderprojects.stooni.ch/
---- Stooni
| 5332 Views | ||
| Go to Top | Next > |


