Smilies: Move `convert_smilies` to happen later in the `the_content` filter.

In particular, we want it to occur after shortcode handling. The smiley conversion routine doesn't have any concept of shortcode structure, so may inadvertantly replace a smiley with HTML inside a shortcode attribute, which will cause the shortcode to not be parsed correctly.

Props Unyson for the initial suggested fix.

Fixes #36306. 


Built from https://develop.svn.wordpress.org/trunk@37298


git-svn-id: http://core.svn.wordpress.org/trunk@37264 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
Gary Pendergast 2016-04-22 07:08:27 +00:00
parent 45b7930627
commit cb7ea89c8e
2 changed files with 2 additions and 2 deletions

View File

@ -130,7 +130,7 @@ add_filter( 'the_title', 'convert_chars' );
add_filter( 'the_title', 'trim' );
add_filter( 'the_content', 'wptexturize' );
add_filter( 'the_content', 'convert_smilies' );
add_filter( 'the_content', 'convert_smilies', 20 );
add_filter( 'the_content', 'wpautop' );
add_filter( 'the_content', 'shortcode_unautop' );
add_filter( 'the_content', 'prepend_attachment' );

View File

@ -4,7 +4,7 @@
*
* @global string $wp_version
*/
$wp_version = '4.6-alpha-37297';
$wp_version = '4.6-alpha-37298';
/**
* Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.