From 31db5d08fe535da5dfca7bfe9221f44aab1fc516 Mon Sep 17 00:00:00 2001 From: Gary Pendergast Date: Mon, 30 Mar 2015 03:09:26 +0000 Subject: [PATCH] Emoji: When staticizing emoji into `` tags, include an `alt` attribute of the original Emoji, to match both Smiley and Twemoji `` tags. Built from https://develop.svn.wordpress.org/trunk@31924 git-svn-id: http://core.svn.wordpress.org/trunk@31903 1a063a9b-81f0-0310-95a4-ce76da25c4cd --- wp-includes/formatting.php | 4 ++-- wp-includes/version.php | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/wp-includes/formatting.php b/wp-includes/formatting.php index 6963e2280f..9386be5e52 100644 --- a/wp-includes/formatting.php +++ b/wp-includes/formatting.php @@ -4275,7 +4275,7 @@ function wp_staticize_emoji( $text ) { $chars = str_replace( array( '&#x', ';'), '', $flag ); list( $char1, $char2 ) = str_split( $chars, 5 ); - $entity = ''; + $entity = sprintf( '%s', $cdn_url . $char1 . '-' . $char2 . $ext, html_entity_decode( $flag ) ); $content = str_replace( $flag, $entity, $content ); } @@ -4290,7 +4290,7 @@ function wp_staticize_emoji( $text ) { if ( ! empty( $matches[1] ) ) { foreach ( $matches[1] as $emoji ) { $char = str_replace( array( '&#x', ';'), '', $emoji ); - $entity = ''; + $entity = sprintf( '%s', $cdn_url . $char . $ext, html_entity_decode( $emoji ) ); $content = str_replace( $emoji, $entity, $content ); } diff --git a/wp-includes/version.php b/wp-includes/version.php index 94a75a5fa6..e17b31535f 100644 --- a/wp-includes/version.php +++ b/wp-includes/version.php @@ -4,7 +4,7 @@ * * @global string $wp_version */ -$wp_version = '4.2-beta3-31923'; +$wp_version = '4.2-beta3-31924'; /** * Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.