Problem

You’re using Divi Theme or Divi Builder, and your images are getting cropped in the Blog, Gallery and/or Portfolio Modules.

 

Solution – Blog

Add this code snippet to your functions.php file.

function ld_blog_crop_image_width($width) {
return 9999;
}
function ld_blog_crop_image_height($height) {
return 9999;
}
add_filter( ‘et_pb_blog_image_width’, ‘ld_blog_crop_image_width’ );
add_filter( ‘et_pb_blog_image_height’, ‘ld_blog_crop_image_height’ );

Solution – Gallery

Add this code snippet to your functions.php file.

function ld_gallery_crop_image_width($size) {
return 9999;
}
function ld_gallery_crop_image_height($size) {
return 9999;
}
add_filter( ‘et_pb_gallery_image_width’, ‘ld_gallery_crop_image_width’ );
add_filter( ‘et_pb_gallery_image_height’, ‘ld_gallery_crop_image_height’ );

Solution – Portfolio

Add this code snippet to your functions.php file.

function ld_portfolio_crop_image_width($width) {
return 9999;
}
function ld_portfolio_crop_image_height($height) {
return 9999;
}
add_filter( ‘et_pb_portfolio_image_width’, ‘ld_portfolio_crop_image_width’ );
add_filter( ‘et_pb_portfolio_image_height’, ‘ld_portfolio_crop_image_height’ );
Previous Next
Close
Test Caption
Test Description goes like this