iso8601_to_datetime
iso8601_to_datetime ( $date_string, $timezone = 'user' )
Parameters:- (string) $date_string Date and time in ISO 8601 format {@link https://en.wikipedia.org/wiki/ISO_8601}.
- (string) $timezone Optional. If set to GMT returns the time minus gmt_offset. Default is 'user'.
Returns:- (string) The date and time in MySQL DateTime format - Y-m-d H:i:s.
Defined at: - Introduced in WordPress: 1.5.0
- Deprecated in WordPress: —
Description
Converts an iso8601 date to MySQL DateTime format used by post_date[_gmt].