Remove WP Emoji Support

WordPress 4.2.2 added emoji support in a pretty annoying way – it injects some js and css in the the wp_head() function with no option to disable this “bonus feature”. I’ve added the functionality to disable emoji support to the Aceify plugin, but if you prefer to include this in your functions instead, here’s what you need:

//remove emoji support
remove_action( 'wp_head', 'print_emoji_detection_script', 7 );
remove_action( 'admin_print_scripts', 'print_emoji_detection_script' );
remove_action( 'wp_print_styles', 'print_emoji_styles' );
remove_action( 'admin_print_styles', 'print_emoji_styles' );