Support

Home Forums Events Calendar Add-on Calendar specific date trick not working!

Calendar specific date trick not working!

Posted: February 7, 2013 at 10:07 am

Viewing 3 reply threads


Edouard Morrissette

February 7, 2013 at 10:07 am

Hi, We have an event on march 21 2013. I would like my calendar to display that date only, in agendaView and from 8am to 16hpm, 24h format. I know we have to modify event-calendar.php according to the gotodate method.

I did the Goto Date part ::

},
imgTimeout
);
// Changer le calendrier pour afficher le 21 mars 2013
$jaer('#espresso_calendar').fullCalendar( 'gotoDate', 2013, 3, 21);

        });

<?php
$buffer = ob_get_contents();
ob_end_clean();

But, the calendar still shows the present date! Now i did refresh my browser and cleaned cache.

Then, I added the snippet of code for the calendar from 8:00 to 16:00 instead of 1am to 12pm


* Agenda Options
* http://arshaw.com/fullcalendar/docs/agenda/
* Note: These ptions that apply to the agendaWeek and agendaDay views, and have beft out intentionally.
* Please refer to the URL above to add.manage your agenda views.
**/

// changes axisFormat to 24 hour
axisFormat: 'HH:mm',
// changes first hour
firstHour: 8,

I deactivated the plugin and reactivated the plugin but it did not work….

Help!


Dean

February 8, 2013 at 3:43 am

Hi,

OK with a little playing about heres what I have got.

First off the time, now this may set it for other view types as well so be aware of that.

On line 450 of espresso-calendar.php it says

$('#espresso_calendar').fullCalendar({

directly below that add

minTime: 8,
maxTime: 17,

Note it is 17 because otherwise it doesnt display the 16.00

Now for the date, the same tplace you had your original code, around line 830

                },
                imgTimeout
            );
                                    $('#espresso_calendar').fullCalendar('gotoDate', 2013, 2, 21);

Note that the Month looks like February but as far as i can tell it is basing that info off of PHP so January is in fact 0, therefore March is 2. Doesnt seem to be the same with the day though.

You end up with something like http://d.pr/i/J1Kp

Note: I couldnt get the time to swap over to 24hr for some reason.


Edouard Morrissette

February 13, 2013 at 7:17 am

Hi Dean, sorry it took me a while to answer… But now, it’s kinda urgent i fix this… I tried your things and my calendar turns out blank!!

Here’s my calendar.php file, can you take a l=ook at it, i’m no programmer, so maybe i forgot a colon or a parenthesis somewhere,,,

https://dl.dropbox.com/u/26582085/espresso-calendar.php
If you can’t dowload it, let me know!
thanks


Dean

February 13, 2013 at 11:46 pm

Hi Eduard,

On line 450 (approx) you had

minTime: 8;
maxTime: 17;

but you need commas not semi colons:

minTime: 8,
maxTime: 17,
Viewing 3 reply threads

The support post ‘Calendar specific date trick not working!’ is closed to new replies.

Have a question about this support post? Create a new support post in our support forums and include a link to this existing support post so we can help you.

Event Espresso