mtbhomer
Forum Replies Created
-
Forum: Plugins
In reply to: [The Events Calendar] Event Calendar past events in list templateI’m checking in on this issue after installing the new event calendar version (4.0.2). It seems a lot has changed from the previous version, and my previous hack stopped working. Is there anything that changed in this version which would make it simpler to achieve this?
To recap, my goal is to have list with previous events that occurred, in order from new to old (newest on top).
Cheers!
Forum: Plugins
In reply to: [The Events Calendar] Event Calendar past events in list templateHi Brook,
Cool! i tried the code with the addition of the is_single() check, but it seems that is_single is not returning a value per default for custom post types.
Instead I check now if the eventDisplay variable is set. It works for my situation. But I guess it’s not perfect in all cases:
// Set the default date for views like List and Month add_action( 'parse_query', 'tribe_set_default_date' ); function tribe_set_default_date () { if ((get_query_var("eventDisplay") == "default") && empty( $_REQUEST['tribe-bar-date'] ) ) { $_REQUEST['tribe-bar-date'] = '2000-01-01'; } }Forum: Plugins
In reply to: [The Events Calendar] Event Calendar past events in list templateHi Brook,
Just want to let you know that adding the code to the theme’s functions.php worked perfectly!
UPDATE: My response might have been a bit premature. I just found out, that adding the request variables code in the theme functions.php will break the single event page. Removing the code from functions.php fixes the issue.
Any recommendation on how to approach it?
Forum: Plugins
In reply to: [The Events Calendar] Event Calendar past events in list templateHi Brook,
Thanks a lot for your suggestion!
I tried to add this code for the request variables both in the lists.php (in view folder) and the loop.php (in list folder). Although I can see the variables are set by echo-ing the variable name. The filtering of the events themselves don’t change (only future events).
Setting it through the address bar still works. Should I set the request variables on an earlier moment? When are they processed?
Best regards,
MartijnForum: Plugins
In reply to: [The Events Calendar] Event Calendar past events in list templateSorry, soft bump this topic. Anyone experience with this plugin who could help me further?