New answers tagged image-resize
From my understanding on how WordPress crops, it's not going to stretch your image to a certain size, so if you upload an image that is 300px wide, it isn't going to stretch the image to 400px, it will keep that width and proportionally create a height. Make sure that Crop thumbnail to exact dimensions (normally thumbnails are proportional) is checked in the ...
WordPress resizes the image when you upload it. By default it provides 4 sizes of your image (providing your image is bigger than the 'large' size). the_post_thumbnail('thumbnail'); // Thumbnail (default 150px x 150px max) the_post_thumbnail('medium'); // Medium resolution (default 300px x 300px max) the_post_thumbnail('large'); ...
A nice explanation is at WPMUdev: http://premium.wpmudev.org/blog/how-to-change-jpeg-compression-in-wordpress/ According to their tutorial, you'd need to add the following to your functions.php add_filter( 'jpeg_quality', create_function( '', 'return 100;' ) ); They also suggest regenerating your thumbnails once the change is made so previously uploaded ...
Adding $attach_data = wp_generate_attachment_metadata( $attach_id, $filename ); wp_update_attachment_metadata( $attach_id, $attach_data ); after $attach_id = wp_insert_attachment( $attachment, $filename); Fixed it.
Top 50 recent answers are included