We're merging with GenerateBlocks! Learn more here.

Support Forum

Please login to receive premium support.

Support for the free plugin can be found here.

Home Forums Pro Support Images not loading in live site if image size is set Reply To: Images not loading in live site if image size is set

#11219
Linda
Participant

Still not working.

I put the following in a code snippet:

//Create a new image size in WP
add_action( ‘after_setup_theme’, function() {
add_image_size( ‘trost-size-name’, 250, 250, true );
} );

//regenerate thumbnails (I did this manually)

//Tell WPSP to use this new size (tried this from first page, then commented out with below specific to my list
//add_filter( ‘wpsp_default_image_size’, function() {
// return ‘trost-size-name’;
//} );

//use it in my show posts list
add_filter( ‘wpsp_default_image_size’, function( $size, $settings ) {
if ( 1215 === $settings[‘list_id’] ) {
return ‘trost-size-name’;
}

return $size;
}, 10, 2 );

——————————————————–
I modified inc/functions.php to replace line 193
the_post_thumbnail( apply_filters( ‘wpsp_default_image_size’, ‘full’, $settings ), array( ‘itemprop’ => ‘image’ ) );
——————————————————–
Still doesn’t take, an inspect on page shows the following
<div class=”wp-show-posts-image wpsp-image-left “>
Advanced Puppy
</div>
——————————————————–
current ngrok link in case you get a chance to view:
http://343ee9c7.ngrok.io/our-classes/
——————————————————–

Any ideas what I might be missing?
Thanks, Linda