Dear EventON Support Team,
we are experiencing two related issues in the function eventon_get_unix_time() located in:
/wp-content/plugins/eventON/includes/eventon-core-functions.php, line 499.
When DateTime::createFromFormat() returns false, the plugin attempts to call .format() on it without a check, which causes a fatal error:
Fatal error: Uncaught Error: Call to a member function format() on false in eventon-core-functions.php on line 499
This can happen if the event start date or time is missing or incorrectly formatted.
We added this fix at line 499:
if ($datetime instanceof DateTime) {
$DD->setDate( $datetime->format(‘Y’), $datetime->format(‘m’), $datetime->format(‘d’));
} else {
return false;
}
This prevents the error – but leads directly to the second issue:
Changes to event date/time are no longer saved
After applying the fix, the post can be saved without crashing, but the updated event date/time is not applied. The UI accepts the change, but the values revert or remain unchanged in the backend. This suggests that when $datetime is false, no valid data reaches the saving function – but there’s no validation or fallback mechanism in place to handle it.
System Info:
WordPress: 6.8.1
PHP: 8.3.2.1
EventON: 4,9.9
Theme: Enfold
Thank you for reviewing this. We would appreciate it if a permanent fix could be included in an upcoming plugin update.
Jun 6,2025 AT 9:59AM - 2 hours ago -Hello,
EventON is available that is supposed to fix the “Call to a member function format() on false” issue. Could you update and let us know?
After applying the fix, the post can be saved without crashing, but the updated event date/time is not applied.
I just did tests and this works correct on 4.9.10 as well. Could you make sure to update the plugin?
EventON is available that is supposed to fix the…
I meant to write “EventON 4.9.10 is available that is supposed to fix the…”.