The “Plugin Check” plugin returns this warning when inspecting a plugin:
Using date_default_timezone_set() and similar isn’t allowed, instead use WP internal timezone support.
This plugin saves dates without timezone offset in database, I’m using strtotime()
for this.
Before saving I force timezone to be UTC+0, so that other plugins cannot intervene (on purpose or by accident):
// get current timezone
$current_zone = date_default_timezone_get();
// set utc timezone for strtotime
date_default_timezone_set('UTC');
Apparently I should use native WP functions for this.
What’s the best way to do this?
Guido
]]>I’m using your plugin and I noticed that the times are managed with UTC, which is not very convenient as I’m in Italy and the times that are returned to me are incorrect (including the times that I display on ActiveCampaign relating to orders placed, cart abandonment, etc…).
Wouldn’t it be possible to adjust the times according to the time zone set in WordPress settings?
I need some help from you to solve this problem. Thank you.
]]>Thanks for this wonderful plugin. It’s really lightweight and does only what we need it to do, so it’s easy to build a design and user flow around it.
I just need help with the timezone.
I have already set my Linux server timezone to Asia/Singapore (+8) and WordPress timezone to Singapore.
However, when I generate a PDF or scan a ticket, the time is still displayed in UTC.
I foresee this to cause confusion among our client’s staff (as well as their patrons) on the day of the event, so it would be great to have an option in the settings page to display the time in the correct timezone.
PS: We have the pro version.
]]>There’s no option for that, and if I add it in, for the calendar id, it fails to load the calendar. Not sure how this hasn’t been reported.. but it’s really annoying as the only thing that displays our calendar events in UTC, is this plugin.. otherwise your phone, or the public calendar page, says which timezone you’re viewing it as.
Example:
https://calendar.google.com/calendar/u/0/embed?src=###########@group.calendar.google.com&ctz=America/Los_Angeles
Sets it to pacific..
]]>It would be appreciated if you can update your plugin to show the Speed Test time stamp in local time, not UTC.
Optional: Show UTC Time followed by Local Time.
Example: (1:11 UTC | 20:11 Local)
Details: https://prnt.sc/_YiCtiLVR_qY
Very confusing for many and requires another step to convert it to local time. 80% of plugins provide time stamps in local time.
Local time can be pulled from WP Dashboard > Settings > General > Timezone
Details: https://prnt.sc/EaOzvF3qiMNS
Helpful: The developers of the plugin, Analytify, made a similar change recently. If necessary, they can assist you to achieve the above.
Thank you!
]]>Around line 241 you are outputting the date, hour, and the minute inputs for the order meta data on the edit order screen.
The previous version of the plugin was outputting it correctly with:
esc_attr( date_i18n( ‘H’, strtotime( $post->post_date ) ) )
The newest version is outputting the UTC time, even with a local timezone set via:
esc_attr( date_i18n( ‘H’, strtotime( $order->get_date_created() ) ) )
This is messing up ALL orders in the admin by showing incorrect date/times and potentially making them get saved incorrectly if they update the order after creation. Needs a fix ASAP
]]>Why should be order details showing universal time instead of local time?
Also, today 2 orders out of 3 in woocommerce orders list, wrote “6 hours ago” instead of 1 hour, but 3rd was correct. I thought maybe on this 2 order system counted time from universal time… (Don’t know why)
]]>P.S. server has the correct date/time.
]]>I don’t understand for example why there is not at least one city for each of the 50 states in the US, but there are 3 cities in North Dakota (Beulah, Center, New Salem). Why is that?
It makes no sense at all. Especially since it is very easy to provide this kind of functionality. All you have to do is add the corresponding cities with their time zones.
Because the problem is not for your users to have to manually enter the corresponding UTC zone (UTC-7, UTC+2, etc.), even if it is a pain to do. The real problem is that I just found out after 5 years of using The Event Calendar Pro, that you don’t recommend using manual offsets like “UTC+1” because it causes potential bugs (https://theeventscalendar.com/extensions/allow-only-location-time-zones-for-events/). It makes no sense that you offer your users the possibility to use manual offsets, if they cause bugs! If it causes bugs, you should just not offer it. That’s just absurd.
So now I just installed version 6.0 of The Event Calendar and The Event Calendar Pro, and after running the migration preview, I get the following message: “We detected one or more events that cannot be properly migrated. Please review the report below for more information. These issues must be resolved before you can migrate your site. Once you have updated or removed problematic events, please re-run the migration preview: The event generated an error: [The start_date and start_date_utc has a conflict when using the timezone of the event.. The end_date_utc does not match the value of end_date with the timezone]. Update the event and try again, or check out our Troubleshooting tips.
What is the solution? I have almost 600 events in my database, most of which use a manual offsets like “UTC+1”. And I can’t re-edit them one by one to be “compatible” with the migration standards, because you offer the option to use manual offsets while they cause bugs.
I hope you are working on a solution that would solve this kind of problem because currently your plugin is not really up to what we can expect from a company like yours. And please, add more location-based time zones to your plugin (at least one city for each of the 50 states in the US…)
Thanks
]]>