Changeset 43389 for trunk/src/wp-includes/functions.php
- Timestamp:
- 07/04/2018 11:42:59 PM (6 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/wp-includes/functions.php
r43387 r43389 89 89 * @param int|bool $timestamp_with_offset Optional. A sum of Unix timestamp and timezone offset in seconds. 90 90 * Default false. 91 * @param bool $gmt Optional. Whether to use GMT timezone. Default false. 91 * @param bool $gmt Optional. Whether to use GMT timezone. Only applies if timestamp is 92 * not provided. Default false. 92 93 * 93 94 * @return string The date, translated if locale specifies it. … … 128 129 if ( preg_match( "/$timezone_formats_re/", $dateformatstring ) ) { 129 130 $timezone_string = get_option( 'timezone_string' ); 131 if ( false === $timestamp_with_offset && $gmt ) { 132 $timezone_string = 'UTC'; 133 } 130 134 if ( $timezone_string ) { 131 135 $timezone_object = timezone_open( $timezone_string ); … … 181 185 * @param string $req_format Format to display the date. 182 186 * @param int $i A sum of Unix timestamp and timezone offset in seconds. 183 * @param bool $gmt Whether to convert to GMT for time. Default false. 187 * @param bool $gmt Whether to use GMT timezone. Only applies if timestamp was 188 * not provided. Default false. 184 189 */ 185 190 $j = apply_filters( 'date_i18n', $j, $req_format, $i, $gmt );
Note: See TracChangeset
for help on using the changeset viewer.