Skip to main content

This site requires you to update your browser. Your browsing experience maybe affected by not having the most up to date version.

All other Modules

Discuss all other Modules here.

Moderators: martimiz, Sean, biapar, Willr, Ingo, swaiba, simon_w

Event Calendar date formats


Reply

4 Posts   970 Views

Avatar
redactuk

16 August 2011 at 1:27pm Community Member, 117 Posts

I have to say i'm still confused about who to go about swapping around the format dates are displayed in the Event Calendar. As my config local is set to:

i18n::set_locale('en_GB');

I was kinda hoping that creating an en_GB file under /events_calendar/lang and swapping around all the formats would do the job, but it does not. Can anyone help me as to how I get that file to be applied? or the proper solutions if that's not it.

Thanks

Avatar
redactuk

18 August 2011 at 11:06am Community Member, 117 Posts

Anyone please help me with this?

Avatar
UncleCheese

19 August 2011 at 1:26am 4085 Posts

In event_calendar/_config.php, you'll see a big block of code for $customDateTemplates. Copy all of that into your mysite/_config.php, uncomment it, and hopefully it's self-explanatory. It's not the prettiest thing in the world, but it gives you the most flexibility.

--------------------
SilverStripe tips, tutorials, screencasts and more: http://www.leftandmain.com

Avatar
wilsonStaff

23 October 2011 at 3:01am Community Member, 142 Posts

Hi, not to hijack, its a similar problem.

Ive succeeded into displaying the calendar in French, using

setlocale(LC_ALL, 'fr_FR.UTF8', 'fr_FR', 'fr-FR', 'french'); into mysite/_config.php

but if it correctly displays the calendar in French, it displays the wrong day/date.

As image below shows, we are SATURDAY 2nd and the calendar displays FRIDAY 22nd.

- - -

My guess is that it picks up the date correctly but as the week starts with Sundat, it offsets everything. So, what to do?

- - -

Uncle?