"All Day Event" Bug in WP3.2 [with Solution]
-
In WordPress 3.2, when making a new event, the “All Day Event” checkbox is checked, yet the time of day settings are displayed. Unchecking the “All Day Event” checkbox hides the time of day options. This makes it impossible to create a non-all-day event.
I tracked down the issue to some incorrect jQuery. WordPress 3.2 ugrades from jQuery 1.4.4 to 1.6.1, and one of the major changes is how jQuery handles checkboxes.
To fix the issue, make the following change.
In /the-events-calendar/views/events-meta-box.php, lines 35-41 read:
if( jQuery('#allDayCheckbox').attr('checked') == true ) { jQuery(".timeofdayoptions").addClass("tec_hide") jQuery("#EventTimeFormatDiv").addClass("tec_hide"); }
Change those lines to:
if( jQuery('#allDayCheckbox').prop('checked', true) ) { jQuery(".timeofdayoptions").addClass("tec_hide"); jQuery("#EventTimeFormatDiv").addClass("tec_hide"); }
This fixes uses the new .prop() method as well as adding a missing semicolon. Without this, I consider the plugin unusable, so it would be great if a new bug fixing release could come out with just this
- The topic ‘"All Day Event" Bug in WP3.2 [with Solution]’ is closed to new replies.