WordPress wrong dates bug
-
I am using WordPress version 5.4.
I have a problem with the dates in a CPT, and it is that the dates show one day less.
Example: If I put in the backend the date, 08/18/20, in the frontend it shows me 08/17/20
I think for some reason the date_i18n function is not executing correctly.
This is the code where I show the dates:
`<time><?php if (isset($event_from_date) && $event_from_date <> ”) echo date_i18n(get_option(‘date_format’), strtotime($event_from_date)) . ‘,’; ?></time>
Viewing 3 replies - 1 through 3 (of 3 total)
Viewing 3 replies - 1 through 3 (of 3 total)
The topic ‘WordPress wrong dates bug’ is closed to new replies.