How to Remove Default Image Upload Compression in wordpress?
You have uploaded images in wordpress and you are showing the image is compressed and image quality is loose.
But if you want to remove the default image compression function, then you can do it easily by placing some script in your functions.php file.
That will remove your wordpress tiny image compression plugin functions and you will get the originial image in your post or pages.
Follow the step below...
Just paste the below function to your theme functions.php file
//Wordpress jpg quality removal function
function tp_jpeg_quality() {
if( class_exists( 'Tiny_Plugin' ) )
return 100;
}
add_filter( 'jpeg_quality', 'tp_jpeg_quality', 20 );
add_filter( 'wp_editor_set_quality', 'tp_jpeg_quality', 20 );
You are done.
Please leave comments if you are facing any problem.
0 Comments