charlesvde
Forum Replies Created
-
Great, found it ! Thank you ??
It does work but I have the same problem as before: it doesn’t display events for september, october, november and december.
I think I will just use [events_list_grouped], but it’s just less flexible so I am trying to modify the events manager template: events-list-grouped.php.
I want to wrap each year in a div with a “year” class.
Unfortunately I can’t find the right place to modify the code… for example, the years are displayed as h2 but I can’t find any h2 in the template… Do you know how they work?
Thank you for your help ??Hi, Thank you for your reply,
If I echo $year, I just get the each year from the loop (from 2008 to 2018).
I actually manage to show the missing events by changing the shortcode:[events_list_grouped mode=’yearly’ limit=0 scope=’all’ orderby=’event_start_date’ order=’ASC’]
But this code doesn’t work in a loop, so I can’t enclose each year in a specific div for filtering: years without events are visible and It’s difficult to target them.
Anyway, it’s already an improvement but I just don’t understand why my loop doesn’t work….
I found what is causing the problem but I don’t know why:
for($year = (date(‘Y’)+3); $year >= 2008; $year–){
$shortcode = do_shortcode(“[events_list orderby=’event_start_date’ year=’$year’]
….So I am doing a loop to display events for each year, if I remove year=’$year’ from the shortcode, the events from september, october, november and december are visible.
But if I keep the year (which I need), they just disapear….Does anyone have the same problem?