CGCalendar Date Setting

Have a question or a suggestion about a 3rd party addon module or plugin?
Let us know here.
KitchM
Power Poster
Power Poster
Posts: 328
Joined: Mon Dec 02, 2013 3:26 am

CGCalendar Date Setting

Post by KitchM »

How does the calendar get the correct date setting?

Thanks.
Last edited by KitchM on Sun Nov 23, 2014 6:28 pm, edited 2 times in total.
Masweb
Forum Members
Forum Members
Posts: 173
Joined: Sat May 09, 2009 4:26 pm
Location: Valkenswaard - Nederland

Re: CGCalendar Date Setting

Post by Masweb »

Go to: Site-admin --> Global Settings and fill the "Date Format String:" filed with a strftime like: %d-%m-%Y
KitchM
Power Poster
Power Poster
Posts: 328
Joined: Mon Dec 02, 2013 3:26 am

Re: CGCalendar Date Setting

Post by KitchM »

Thank you very much for the advice. I tried as you suggested but my calendar month is still incorrect. It is one month too early. This is October but it displays November.
User avatar
Jo Morg
Dev Team Member
Dev Team Member
Posts: 1930
Joined: Mon Jan 29, 2007 4:47 pm

Re: CGCalendar Date Setting

Post by Jo Morg »

Again: search the forums. It has been asked and answered a few times.
"There are 10 types of people in this world, those who understand binary... and those who don't."
* by the way: English is NOT my native language (sorry for any mistakes...).
Code of Condut | CMSMS Docs | Help Support CMSMS
My developer Page on the Forge
GeekMoot 2015 in Ghent, Belgium: I was there!
GeekMoot 2016 in Leicester, UK: I was there!
DevMoot 2023 in Cynwyd, Wales: I was there!
Masweb
Forum Members
Forum Members
Posts: 173
Joined: Sat May 09, 2009 4:26 pm
Location: Valkenswaard - Nederland

Re: CGCalendar Date Setting

Post by Masweb »

KitchM wrote:Thank you very much for the advice. I tried as you suggested but my calendar month is still incorrect. It is one month too early. This is October but it displays November.
display="upcominglist" displayforday="true"
KitchM
Power Poster
Power Poster
Posts: 328
Joined: Mon Dec 02, 2013 3:26 am

Re: CGCalendar Date Setting

Post by KitchM »

Thanks for the tip.

Tried it but got no change. I probably put it in the wrong spot in the CSS.
Masweb
Forum Members
Forum Members
Posts: 173
Joined: Sat May 09, 2009 4:26 pm
Location: Valkenswaard - Nederland

Re: CGCalendar Date Setting

Post by Masweb »

Can you give us a url? Or a piece of your template you are using?
staartmees
Power Poster
Power Poster
Posts: 1049
Joined: Wed Mar 19, 2008 4:54 pm

Re: CGCalendar Date Setting

Post by staartmees »

Search The forum. It's a known problem and I somewhere posted a solution. Also Rolf posted a solution.
http://forum.cmsmadesimple.org/viewtopi ... ar#p313618
Last edited by staartmees on Wed Oct 29, 2014 8:16 pm, edited 1 time in total.
User avatar
paulbaker
Dev Team Member
Dev Team Member
Posts: 1465
Joined: Sat Apr 18, 2009 10:09 pm
Location: Maidenhead, UK
Contact:

Re: CGCalendar Date Setting

Post by paulbaker »

KitchM
Power Poster
Power Poster
Posts: 328
Joined: Mon Dec 02, 2013 3:26 am

Re: CGCalendar Date Setting

Post by KitchM »

I am so embarrased. :-[

Of all the times I've searched a subject, this was the first time I did not. And the answers are all over the place.

Please forgive me.

Someone had already helped me with changing some code in the script months ago. Then it evidently stopped working correctly.

So instead of the part that was added before

Code: Select all

{$month_names[$month]}
I now have

Code: Select all

{$date|date_format:'%B'}
Now it works properly.

Thanks very much for everyone's help. It is appreciated.
staartmees
Power Poster
Power Poster
Posts: 1049
Joined: Wed Mar 19, 2008 4:54 pm

Re: CGCalendar Date Setting

Post by staartmees »

Please add [Solved] to the titel.
KitchM
Power Poster
Power Poster
Posts: 328
Joined: Mon Dec 02, 2013 3:26 am

Re: [Solved] CGCalendar Date Setting

Post by KitchM »

With my fingers crossed that it doesn't change again.....
cromoglic
New Member
New Member
Posts: 2
Joined: Wed Jun 15, 2011 10:16 pm

Re: [Solved] CGCalendar Date Setting

Post by cromoglic »

This solution does not work for me. I've got this in my list template:

Code: Select all

<span class="calendar-prev"><a class="button" href="{$navigation.prev}">&laquo;</a></span>&nbsp;<span class="button">{*$month_names[$month]*}{$date|date_format:'%B'}&nbsp;{$year}</span>&nbsp;<span class="calendar-next"><a class="button" href="{$navigation.next}">&raquo;</a></span>
$date|date_format:"%B" shows nothing. Changing date to $month shows nothing. Removing date_format when using $month shows the number of the month, which isn't exactly what I am after.

Anyone? :)
User avatar
paulbaker
Dev Team Member
Dev Team Member
Posts: 1465
Joined: Sat Apr 18, 2009 10:09 pm
Location: Maidenhead, UK
Contact:

Re: [Solved] CGCalendar Date Setting

Post by paulbaker »

@cromoglic post your system information
http://docs.cmsmadesimple.org/troublesh ... nformation
User avatar
Rolf
Power Poster
Power Poster
Posts: 7825
Joined: Wed Apr 23, 2008 7:53 am
Location: The Netherlands
Contact:

Re: [Solved] CGCalendar Date Setting

Post by Rolf »

cromoglic wrote:$date|date_format:"%B" shows nothing. Changing date to $month shows nothing. Removing date_format when using $month shows the number of the month, which isn't exactly what I am after.
Try:

Code: Select all

{$thedate|date_format:"%B"}
- + - + - + - + - + - + -
LATEST TUTORIAL AT CMS CAN BE SIMPLE:
Migrating Company Directory module to LISE
- + - + - + - + - + - + -
Image
Post Reply

Return to “Modules/Add-Ons”