[wp-trac] [WordPress Trac] #39595: date_default_timezone_set in wp-settings.php is set prematurely and ignorantly, regardless of other defined settings
WordPress Trac
noreply at wordpress.org
Mon Jan 16 01:37:09 UTC 2017
#39595: date_default_timezone_set in wp-settings.php is set prematurely and
ignorantly, regardless of other defined settings
-------------------------------+------------------------------
Reporter: mkormendy | Owner:
Type: defect (bug) | Status: new
Priority: normal | Milestone: Awaiting Review
Component: Date/Time | Version: 4.7.1
Severity: normal | Resolution:
Keywords: reporter-feedback | Focuses:
-------------------------------+------------------------------
Comment (by mkormendy):
I realized that this was likely in trac for a long time and maybe a
revision may be in order.
I was trying to be as verbose as possible, trust me, I could have gone WAY
WAY more in depth, you should be grateful that this is the middle-ground
you're getting ;-)
Boiling down: yes, timestamps is one reason. But I'm also noticing that
some plugins (major players: gravity forms, yoast seo, contact form DB)
also don't store or report times correctly either because they expect the
default PHP timezone to be either what is in `php.ini` -OR- what is stored
in the WP Admin General Settings (wp_options: `gmt_offset` and
`timezone_string`).
The force in wp-settings.php just feels "hijacky" because it forces a
timezone for the entire wordpress application versus just the methods
where time is stored and reported.
Lastly, thanks for your honest opinion, I'd hate for you to have dishonest
ones. :-) But, if operating system or server software developers didn't
want you configuring the local time, they wouldn't have allowed options
like SetEnv TZ or date.timezone.
(I also realize just because they have these, it doesn't mean you should
set these, but a reasonable amount of WP-based websites might not have a
choice if its set to local time of the server).
--
Ticket URL: <https://core.trac.wordpress.org/ticket/39595#comment:2>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform
More information about the wp-trac
mailing list