#32080 closed enhancement (duplicate)
Emoji inline styles & script to not get loaded when convert emoticons is disabled in the admin (>=4.2)
Reported by: |
|
Owned by: | |
---|---|---|---|
Milestone: | Priority: | normal | |
Severity: | normal | Version: | 4.2 |
Component: | Formatting | Keywords: | |
Focuses: | performance | Cc: |
Description
Since the option discards the conversion of emoji, there would be no need for the styles and script to load at all.
I had manually set this up by removing the action from inside the theme according to the value of the get_option( 'use_smilies' ), but I think this would be worth to be included inside
wp-includes/formatting.php
!( get_option( 'use_smilies' ) ) before the return condition. |
function print_emoji_styles() { static $printed = false; if ( $printed || !( get_option( 'use_smilies' ) ) ) { return; }
and
function print_emoji_detection_script() { global $wp_version; static $printed = false; if ( $printed || !( get_option( 'use_smilies' ) ) ) { return; }
Attachments (1)
Change History (5)
Note: See
TracTickets for help on using
tickets.
Tested formatting.php file