12Mar

Remove WordPress wp-embed js script of your page template

Here is a quick tip to remove the piece of code added by WordPress 4.4 in the header of your pages about wp-embed.

wp-embed.js is a script added by wordpress
It’s super easy to embed videos, images, tweets, audio, and other content into your WordPress site. This feature was added in WordPress 2.9″

That’s the code WordPress adds in your page:

function my_deregister_scripts(){
wp_deregister_script( 'wp-embed' );
}
add_action( 'wp_footer', 'my_deregister_scripts' );

 

Easy!

Read more at: https://codex.wordpress.org/Embeds

Leave a Reply