• I have a gift card plugin that features a scheduled delivery, so the customer can choose what date it is emailed to the recipient. The plugin works great however the gift card is delivered in UTC time even though I have my time zones set to America/New_York in my php.ini and to New York in WordPress settings. The only way I have been able to get it to send at the correct date/time scheduled is to change the code in wp-settings.php from date_default_timezone_set( ‘UTC’ ); to date_default_timezone_set( ‘America/New_York’ ); then sync up the time zone in wordpress general settings. I’m concerned that by doing this it may cause some unforeseen issues, so far it seems ok but I want to be certain I’m not breaking anything. I also have been working with the plugins developers but they can’t find any issue with the code. Any advice is greatly appreciated.

    The page I need help with: [log in to see the link]

Viewing 3 replies - 1 through 3 (of 3 total)
  • Hello, it’s not a good idea to override the time zone in wp-settings.php. It should be left as UTC. Is the time displaying correctly on your WordPress site?

    Thread Starter giomorin

    (@giomorin)

    Thanks for your quick reply. I figured it may not be the best solution.The time is displaying correctly on the site as my local time. So far developer of the plugin has not been able to figure out the issue. The only way I have been able to get the scheduled gift card to be delivered at the right time is to change the default to America/New_York in the wp-settings file, otherwise it gets delivered at 8:14pm the the day before it was scheduled (4 hrs early). I’m stumped.

    Hi, are you able to set the delivery time in the plugin? Maybe you can convert from EST to UTC as a temporary workaround.

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘default Timezone in wp-setting.php’ is closed to new replies.