New events calendar template

7 years 2 months ago #33155 by ggppdk
Replied by ggppdk on topic New events calendar template
The new filters (soon available) for created/modified fields (creation time/modification time) and for date fields, support group filtering per year, or month or day

Is this what you mean/need?


-- Flexicontent is Free but involves a big effort on our part.
Like the our support? (for a bug-free FC, despite having a long list of functions) Like the features? Like the ongoing development and future commitment to FLEXIcontent?
-- Add your voice to the FLEXIcontent JED listing with a 5-star review. Thanks!

Please Log in or Create an account to join the conversation.

7 years 2 months ago #33162 by micker
Replied by micker on topic New events calendar template
cool

FLEXIcontent is Free but involves a very big effort on our part.
Like the our support? (for a bug-free FC, despite being huge extension) Like the features? Like the ongoing development and future commitment to FLEXIcontent?
-- Add your voice to the FLEXIcontent JED listing reviews. Thanks![/size]

Please Log in or Create an account to join the conversation.

7 years 2 months ago #33163 by fgossart
I this month calendar view template, I just like to have some links to browser months/years.
In the template I put some parameters to have x months before and after, but there is no effects.

Please Log in or Create an account to join the conversation.

7 years 2 months ago #33168 by igcorreia
I am also preparing a project to work with this template.

Baiscly each item is an EVENT. So if the user want to search what are the events available from THIS DATE to THAT DATE is this possible? This would be great.

Please Log in or Create an account to join the conversation.

7 years 2 months ago #33169 by fgossart
I will try now to debug the template and hope to understand how it works

Please Log in or Create an account to join the conversation.

7 years 2 months ago #33177 by fgossart
I think I have found a first bug in settings Display Events in future (custom value).
Actually the value has no effect, all the futures events are displayed.
In category_items.php i change the < with > on the second check . I think it's copied from before and not correct.
if ($displayEventsInFuture == 2) {
if (($dateToCheck[1] > ($today[1] + $displayEventsMonthInFutureCustom)) && ($dateToCheck2[1] > ($today[1] + $displayEventsMonthInFutureCustom)))
continue; // skip it < event doesnt lie in the current month's time range ($today[1] = month e.g. 4)}


it feels better now, I still have to found now how I could navigate through past and future months if possible.

Please Log in or Create an account to join the conversation.

7 years 2 months ago #33181 by fgossart
another bug ?
Month names ares displayed with bad encoding (février)
In source code it's easyier to use
$monthNames[$nameKey]=JDate::monthToString($nameKey);
and comment //$monthNames[$nameKey] = date('m', strtotime('2012-' . $nameKey));
and comment //$monthNames[$nameKey] = utf8_encode(strftime($MonthDateFormat, strtotime('2012-' .$monthNames[$nameKey])));


and another change
//$startMonth = utf8_encode(strftime('%B', strtotime($startDate)));
$startMonth = $monthNames[intval(strftime('%m', strtotime($startDate)))];

in category_items.php

Please Log in or Create an account to join the conversation.

7 years 1 month ago #33241 by Rehne
Replied by Rehne on topic New events calendar template
Hi,

please excuse my late response
unfortunately i'm not able to do much because of my bad health
but i would like to respond to a few points / questions
First let me say that I have the adapted the event template of Andrew to the needs of my clients … i am not specialized in PHP programming so i think a lot could be possibly better resolved

Now for the comments:

1. Template Position ‘table’

ggppdk wrote: I see that the category_items.php is not using the template position 'table'
The template will have to be updated to use this and or other template positions…

i do not understand why a table position must be present …. for this case
the render-only position is still available / sufficient … i think a table-position would be misleading to the user because the user is expected a output of a table but the category template don’t yous a table-view yet

2. use/show image field

fgossart wrote: I just try to put image field value (with eventually multiple images as gallery) just before description and I don't see any problem. …

as i said in a previous post
the display of an image (gallery) should be no problem (you have already been made it)
only when ….
e.g. you apply an Multiday event and for the individual dates are different images associates
in the item-view the event fields will be sorted (by php array_multisort) to show the next upcoming date as the first …. but somehow I have problems with images in an array
…. understandable what I mean ….

3. month selector
for this you must be set a few Options in the Template Params > Parameters: LIST LAYOUT
(see attachment)[attachment=0:179xfsha]<!-- ia0 -->event_template_accordion.JPG<!-- ia0 -->[/attachment:179xfsha]

NOTE:
A multiday event actually only appears once as a accordion
which is not correct if the multiday-event go over several months
you have to be modified the following in the gategory-items template to change the behavior
delete line 640
if ( ($event_catViewLayout == 1) && ($i > $event_startDay) )  continue; // show the event only one time (only in the start month) in the list layout

and put in place of at line 652 after
$eventMonthKey = $m + $monthAdjust;
following code
// show the event only one time (in all month) in the list layout	
$event_MonthKey[$i] = $eventMonthKey; 
if (isset($event_MonthKey[$i - 1])) {
if ( ($event_catViewLayout == 1) && ($event_MonthKey[$i] == $event_MonthKey[$i - 1]) )  continue;  
}

4. future and past events

fgossart wrote: I this month calendar view template, I just like to have some links to browser months/years.
In the template I put some parameters to have x months before and after, but there is no effects.

i have tested this function again now … mmm…
do you have the problems with Multiday events, or one-day events, calendar- or list-view?
possibly see the NOTE before

but what I have noticed
the param “show EMPTY“ month not working properly for multiday-events fall in multiyears … sorry
i recommend to create one category per year and don’t show empty month
that's what i made in my projects where I used the template … without any Problem

5. Bugs

fgossart wrote: I think I have found a first bug in settings Display Events in future (custom value).
Actually the value has no effect, all the futures events are displayed.
In category_items.php i change the < with > on the second check . I think it's copied from before and not correct…...

thanks … that’s right … i think that the ‘&&’ must also be changed in ‘||’ !?
so the right code is
if ($displayEventsInFuture == 2) {	 
if (($dateToCheck[1] > ($today[1] + $displayEventsMonthInFutureCustom)) || ($dateToCheck2[1] > ($today[1] + $displayEventsMonthInFutureCustom))) continue; 
}

fgossart wrote: another bug ?
Month names ares displayed with bad encoding (février)
In source code it's easyier to use….

have you tested it already - with different languages etc. ?
i'm going to look at you when i'm healthy again
i hope soon

Regards
Attachments:

Please Log in or Create an account to join the conversation.

7 years 1 month ago #33255 by Rehne
Replied by Rehne on topic New events calendar template

fgossart wrote: I think I have found a first bug in settings Display Events in future (custom value).
Actually the value has no effect, all the futures events are displayed.
In category_items.php i change the < with > on the second check . I think it's copied from before and not correct.
if ($displayEventsInFuture == 2) {
if (($dateToCheck[1] > ($today[1] + $displayEventsMonthInFutureCustom)) && ($dateToCheck2[1] > ($today[1] + $displayEventsMonthInFutureCustom)))
continue; // skip it < event doesnt lie in the current month's time range ($today[1] = month e.g. 4)}


it feels better now, I still have to found now how I could navigate through past and future months if possible.


Hi,

I have now changed this (show events in past / future)
as i have do some tests and still found several other problems
the new one (code) works
what to do:

delete lines 544-558 (between $yearDiff = $dateToCheck[0] - $today[0]; AND $monthAdjust = 0;
// if event year < current year OR (event year is current year and event month < current month)
// show no events in past
if ($displayEventsInPast == 0) { // 0 = No, 1 = all, 2 = custom ($displayEventsMonthInPastCustom)
    if ( $yearDiff < 0 || ($yearDiff == 0 && $dateToCheck[1] < ($today[1])) ) continue; // skip it < event doesnt lie in the current month's time range ($today[1] = month e.g. 4)
}
if ($displayEventsInPast == 2) {
    if (($dateToCheck[1] < ($today[1] - $displayEventsMonthInPastCustom)) && ($dateToCheck2[1] < ($today[1] - $displayEventsMonthInPastCustom))) continue;
}
// show no events in future  // Kontrollieren
if ($displayEventsInFuture == 0) { // 0 = No, 1 = all, 2 = custom ($displayEventsMonthInFutureCustom)
    if ( $yearDiff > 0 || ($yearDiff == 0 && $dateToCheck[1] > ($today[1])) ) continue; // skip it < event doesnt lie in the current month's time range ($today[1] = month e.g. 4)
}		
if ($displayEventsInFuture == 2) {	 
    if (($dateToCheck[1] > ($today[1] + $displayEventsMonthInFutureCustom)) || ($dateToCheck2[1] > ($today[1] + $displayEventsMonthInFutureCustom))) continue; 
}
 
delete lines 606-614 (between $multiYearAdjust = ($eventDate[1][0] - $eventDate[0][0]) * 12; AND $i = $eventDate[0][2];
if ($eventDate[0][0] == $today[0] && $eventDate[0][1] < $today[1]) { // $today[0] = year int e.g. 2011, $today[1] = month e.g. 4
    // if it's the same year and before the current month and choose DISPLAY events in past = no, set $eventDate to 1st of today's month
    if ( ($displayEventsInPast == 0) || ( ($displayEventsInPast == 2) && ($displayEventsMonthInPastCustom < 1)) ) { // 0 = No, 1 = all, 2 = custom
        $eventDate[0][1] = $today[1]; // $today[1] = month e.g. 4
        $eventDate[0][2] = 1;
    }
}

delete line 623
if ( ($displayEventsInFuture == 1) || (($displayEventsInFuture == 2) && ($displayEventsMonthInFutureCustom > 0)) ) {
    $event_endDay += $eventDate[1][2]; // = month e.g. 7 // Kontrollieren
}

ad following new lines after $eventMonthKey = $m + $monthAdjust;
// show no event in past
if ( ($displayEventsInPast == 0) || ( ($displayEventsInPast == 2) && ($displayEventsMonthInPastCustom < 1)) ) { 
    if ( ($y < $today[0]) || ($y == $today[0] && $m < $today[1] ) )   continue;  
}
// show custom event in past
if ($displayEventsInPast == 2) {
    if ( (($y < $today[0]) && ($m < ($today[1] - $displayEventsMonthInPastCustom + 12))) 
        || (($y == $today[0]) && $m < ($today[1] - $displayEventsMonthInPastCustom)) )   continue;  
}
// show no event in future
if ( ($displayEventsInFuture == 0) || (($displayEventsInFuture == 2) && ($displayEventsMonthInFutureCustom < 1)) ) {
    if ( ($y > $today[0]) || ($y == $today[0] && $m > $today[1] ) )   continue;  
}
// show custom event in future 
if ($displayEventsInFuture == 2) {
    if ( (($y > $today[0]) && $m > ($today[1] + $displayEventsMonthInFutureCustom)) 
        || (($y == $today[0]) && $m > ($today[1] + $displayEventsMonthInFutureCustom)) )   continue;  
}
 
// show the event only one time (in all month) in the list layout
$event_MonthKey[$i] = $eventMonthKey; 
if (isset($event_MonthKey[$i - 1])) {
    if ( ($event_catViewLayout == 1) && ($event_MonthKey[$i] == $event_MonthKey[$i - 1]) )  continue;  
}


thats it

Regards

Please Log in or Create an account to join the conversation.

7 years 1 month ago #33259 by fgossart
I will put your changes soon. Thanks

Please Log in or Create an account to join the conversation.

Moderators: vistamediajoomlacornerggppdk
© 2018 Flexicontent. All Rights Reserved.