From 60252611bef58e8d9ecf336e30399c8126fc0d14 Mon Sep 17 00:00:00 2001 From: John Blackbourn Date: Thu, 5 Jul 2018 23:10:25 +0000 Subject: [PATCH] Date/Time: Add support for the `c` and `r` shorthand formats in `date_i18n()`. Props Rarst, pbearne Fixes #20973 Built from https://develop.svn.wordpress.org/trunk@43434 git-svn-id: http://core.svn.wordpress.org/trunk@43261 1a063a9b-81f0-0310-95a4-ce76da25c4cd --- wp-includes/functions.php | 3 +++ wp-includes/version.php | 2 +- 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/wp-includes/functions.php b/wp-includes/functions.php index 9fba7917d6..8ae58299d6 100644 --- a/wp-includes/functions.php +++ b/wp-includes/functions.php @@ -107,6 +107,9 @@ function date_i18n( $dateformatstring, $timestamp_with_offset = false, $gmt = fa */ $req_format = $dateformatstring; + $dateformatstring = preg_replace( "/(?month ) ) && ( ! empty( $wp_locale->weekday ) ) ) { $datemonth = $wp_locale->get_month( date( 'm', $i ) ); $datemonth_abbrev = $wp_locale->get_month_abbrev( $datemonth ); diff --git a/wp-includes/version.php b/wp-includes/version.php index 10e9e01b75..5a222e871e 100644 --- a/wp-includes/version.php +++ b/wp-includes/version.php @@ -4,7 +4,7 @@ * * @global string $wp_version */ -$wp_version = '5.0-alpha-43406'; +$wp_version = '5.0-alpha-43434'; /** * Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.