[wp-trac] [WordPress Trac] #48733: Problems with date after replacing date_i18n() with wp_date()
WordPress Trac
noreply at wordpress.org
Tue Nov 19 21:12:06 UTC 2019
#48733: Problems with date after replacing date_i18n() with wp_date()
---------------------------+----------------------
Reporter: Guido07111975 | Owner: (none)
Type: defect (bug) | Status: closed
Priority: normal | Milestone:
Component: Date/Time | Version: 5.3
Severity: normal | Resolution: invalid
Keywords: | Focuses:
---------------------------+----------------------
Changes (by Rarst):
* status: new => closed
* resolution: => invalid
* milestone: Awaiting Review =>
Comment:
Please note [https://developer.wordpress.org/reference/functions/wp_date/
`wp_date()` documentation]:
> Note that, unlike `date_i18n()`, this function accepts a true Unix
timestamp, not summed with timezone offset.
If you are passing WP timestamp (a sum of Unix timestamp and time zone
offset) to it then it won't produce correct result.
[https://make.wordpress.org/core/2019/09/23/date-time-improvements-wp-5-3/
Dev note for the component changes] has some more details.
--
Ticket URL: <https://core.trac.wordpress.org/ticket/48733#comment:1>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform
More information about the wp-trac
mailing list