simonc17
Forum Replies Created
-
Forum: Plugins
In reply to: [Events Manager - Calendar, Bookings, Tickets, and more!] What day is it?Try this css:
.em.em-calendar .em-cal-body .eventless-today .em-cal-day-date.em-cal-day-date span, .em.em-calendar .em-cal-body .eventfull-today .em-cal-day-date.em-cal-day-date span {
background: #yourcolorhere;
color: #yourtextcolorhereifyouwanttochangejustforthecurrentday !important;
}This should cover days when you have and do not have any events. You might want to check what it looks like on a small calendar if you use one to ensure the coloured event segments (if you have event category colours) show up against the date background.
- This reply was modified 1 month ago by simonc17.
Forum: Plugins
In reply to: [Events Manager - Calendar, Bookings, Tickets, and more!] What day is it?I highlight the current day on the calendar using this custom css:
.em.em-calendar .em-cal-body .eventful-today, .em.em-calendar .em-cal-body .eventless-today {
background-color: your-color-here;
}Thanks for coming back.
Here is a calendar on the live site which is running EM 6.5.1: https://ottervalechurches.org/connect/ovmc-events/
I have just copied this to a staging site and the only change is to upgrade the staging site to EM 6.5.2. Here is the same page as above: https://staging.ottervalechurches.org/connect/ovmc-events/
If you filter the live site calendar on a mobile device, you will see when you expand ‘Filter by parish’ (filtering by category) the text search field above the list of parishes. You can then just select one or more parishes and click search. If you do this using the staging site, you will see no search field, just a dropdown field with 0 items text. If you click this then the list of categories is displayed in a separate panel in a totally different style to the rest of EM.
As mentioned, all I have done is upgrade to 6.5.2 so this upgrade is breaking category filter selection on mobile somehow.
Thanks for coming back.
Here is a calendar on the live site which is running EM 6.5.1: https://ottervalechurches.org/connect/ovmc-events/
I have just copied this to a staging site and the only change is to upgrade the staging site to EM 6.5.2. Here is the same page as above: https://staging.ottervalechurches.org/connect/ovmc-events/
If you filter the live site calendar by choosing Ottery St Mary from the list of parishes (categories) and then go forward one month, you will see that the filter stays applied. If you do the same on the staging site, you will see that the selected parish is still selected for the next month but is not applied as a filter to the calendar with all parish events being shown. On both sites however, you can type ottery into the main search bar and click search, and this filter is properly applied on both sites and remains moving forward and back months.
As mentioned, all I have done is upgrade to 6.5.2 so this upgrade is breaking filtering by advanced search category selection somehow. This makes me think it has to be the removal of unnecessary parameters in the calendar query string that is somehow causing this.
- This reply was modified 3 months, 1 week ago by simonc17.
Thanks for coming back.
Here is a calendar on the live site which is running EM 6.5.1: https://ottervalechurches.org/connect/ovmc-events/
I have just copied this to a staging site and the only change is to upgrade the staging site to EM 6.5.2. Here is the same page as above: https://staging.ottervalechurches.org/connect/ovmc-events/
If you navigate on the live site calendar forward to January 2025 you will see a long event correctly displayed across 5 days. This is using the EM settings option to display long events on the full calendar (so not in the calendar shortcode). If you do the same on the staging site you will see it is displayed on the first day only.
As mentioned, all I have done is upgrade to 6.5.2 so this upgrade is breaking this long events setting somehow. If I turn off the long events option in settings and use long_events=1 in the calendar shortcode it works OK. This makes me think it has to be the removal of unnecessary parameters in the calendar query string that is somehow causing this.
I’ve tracked the broken next month issue down to browser caching. I had the issue sorted on my desktop but when I went to my mobile or laptop devices to check, the issue still occurred. I had to clear the browser cache on each device for the EM calendar to then work properly.
I wonder if this is something to do with the browser caching the old query string params which then caused EM an issue. Only by clearing the browser cache did the new query params then get used. If this is the case then this is a real issue.
OK thanks. On the first issue, i’ll put it down to a temporary glitch.
On the long events, I had this set as a default in Settings > Formatting > Calendar > Full size calendar > Show long events. Switching this off and then adding the parameter long_events=1 into the shortcode fixed the issue.
What I am seeing now though is that if I have a long event shown on the calendar so it goes across multiple days, then move forward and back one month, the event is only shown on its start day. Refreshing the browser then displays it correctly. Is this something you also see? If so, I’ll raise it as a separate issue.
Thanks for replying. The functions are:
add_filter( ’em_events_build_sql_conditions’, ‘my_em_rolling_7_days_scope_conditions’,1,2);
function my_em_rolling_7_days_scope_conditions($conditions, $args){
if( !empty($args[‘scope’]) && $args[‘scope’]==’rolling-7-days’ ){
$start_date = date(‘Y-m-d’,current_time(‘timestamp’));
$tomorrow_date = date(‘Y-m-d’,strtotime(‘+1 day’,current_time(‘timestamp’)));
$end_date = date(‘Y-m-d’,strtotime(‘+7 day’,current_time(‘timestamp’)));
$conditions[‘scope’] = ” ((event_end_date = CAST(‘$start_date’ AS DATE) AND event_end_time > CAST(NOW() AS TIME)) OR (event_start_date BETWEEN CAST(‘$tomorrow_date’ AS DATE) AND CAST(‘$end_date’ AS DATE)) OR (event_start_date <= CAST(‘$start_date’ AS DATE) AND (event_end_date > CAST(‘$start_date’ AS DATE))))”;
}
return $conditions;
}add_filter( ’em_events_build_sql_conditions’, ‘my_em_rolling_30_days_scope_conditions’,1,2);
function my_em_rolling_30_days_scope_conditions($conditions, $args){
if( !empty($args[‘scope’]) && $args[‘scope’]==’rolling-30-days’ ){
$start_date = date(‘Y-m-d’,current_time(‘timestamp’));
$tomorrow_date = date(‘Y-m-d’,strtotime(‘+1 day’,current_time(‘timestamp’)));
$end_date = date(‘Y-m-d’,strtotime(‘+30 day’,current_time(‘timestamp’)));
$conditions[‘scope’] = ” ((event_end_date = CAST(‘$start_date’ AS DATE) AND event_end_time > CAST(NOW() AS TIME)) OR (event_start_date BETWEEN CAST(‘$tomorrow_date’ AS DATE) AND CAST(‘$end_date’ AS DATE)) OR (event_start_date <= CAST(‘$start_date’ AS DATE) AND (event_end_date > CAST(‘$start_date’ AS DATE))))”;
}
return $conditions;
}I then use these scopes not in the calendar shortcodes but in events list shortcodes elsewhere.
OK, I thought the issue might be related to a dodgy event so deleted all events from a staging site to test and the calendar still didn’t work properly. After restoring the staging site, I then commented out two custom scope functions in functions.php and cleared the browser cache and then the calendar worked properly. Uncommenting them and clearing the browser cache still left the calendar working OK. So why did two functions that worked OK before 6.5.2 have to effectively be recreated for 6.5.2 to work?
Here’s some more info:
If I click on the next month button (or use the month picker to pick September) after I have navigated to the page with the calendar on, I get the issue detailed above. In the month picker in the top left of the calendar, the display changes to 2024-09 and it is just a text field, not a month picker. The Today button is also missing.
If I then click on the Next month button again to load October, the entire page reloads and is displayed correctly with October in the calendar. If I then click on the month picker again to load November, the issue occurs again. If I click on the month picker again to load December, the page reloads and everything is displayed correctly. This sequence of working and not working repeats continuously.
Found these finally under calendar search: https://wp-events-plugin.com/documentation/event-search-attributes/?_highlight=long/documentation/event-search-attributes/#calendar-parameters
Still not fixed in 6.4.7.3, pretty poor. If your trying to select the item at the bottom of the list you have to use arrow and return keys to do it which users won’t figure to do. Come on Marcus, please fix this.
Couldn’t agree more. This should have definitely been fixed as event creators can easily select the wrong location. I raised the issue originally and fully expected this to be fixed as it is a bad bug.
I just tested this issue in Firefox, Safari, Brave, Edge and Chrome on EM version 6.4.7 and the only browser where the bug doesn’t occur is Firefox.