Problem:
The date picker was displaying a date one day earlier than the date selected in the calendar (e.g., selecting Feb 4 showed Feb 3 in the input field), even though the WordPress timezone was set correctly. The issue occurred both on localhost and on the production site.
Solution:
The issue was caused by a global date_default_timezone_set('Asia/Manila') call introduced by the QuickBooks PHP SDK. Setting the PHP default timezone to a non-UTC value affected the JavaScript/PHP date handling used by the date picker, resulting in an off-by-one-day shift. Removing this call or keeping the default timezone as UTC resolved the issue and restored correct date selection behavior.
This is the technical support forum for Toolset - a suite of plugins for developing WordPress sites without writing PHP.
Everyone can read this forum, but only Toolset clients can post in it. Toolset support works 6 days per week, 19 hours per day.
This topic contains 1 reply, has 1 voice.
Last updated by 5 days, 8 hours ago.
Assisted by: Christopher Amirian.