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:

Description

Converts an iso8601 date to MySQL DateTime format used by post_date[_gmt].

Related Functions

is_date, is_time, iso8601_timezone_to_offset, is_local_attachment, option_update_filter

Top Google Results

User discussions

wpseek mobile