WordPress at a glance
function is not described

mysql_to_rfc3339() WP 4.4.0

Parses and formats a MySQL datetime (Y-m-d H:i:s) for ISO8601/RFC3339.

Explicitly strips timezones, as datetimes are not saved with any timezone information. Including any information on the offset could be misleading.

No Hooks.

Return

String. Date formatted for ISO8601/RFC3339.

Usage

mysql_to_rfc3339( $date_string );
$date_string(string) (required)
Date string to parse and format.

Code of mysql to rfc3339: wp-includes/functions.php VER 5.0.3

<?php
function mysql_to_rfc3339( $date_string ) {
	$formatted = mysql2date( 'c', $date_string, false );

	// Strip timezone information
	return preg_replace( '/(?:Z|[+-]\d{2}(?::\d{2})?)$/', '', $formatted );
}