WordPress.org

Ready to get started?Download WordPress

Forums

Carousel Horizontal Posts Content Slider
Thumbnails not show cropped version. (3 posts)

  1. lduvall
    Member
    Posted 1 year ago #

    I am trying to display the thumbnail version of the featured image. However, it isn't showing up that way. My thumbnail size is 150px x 150px. I have changed the default size within the plugin code to be 150px x 150px as well as the css.

    However, it is squishing the picture or stretching it to fit, instead of using the cropped 150px x 150px version.

    Can you please help me figure out how to adjust this to work?

    http://wordpress.org/extend/plugins/carousel-horizontal-posts-content-slider/

  2. nextart
    Member
    Posted 4 months ago #

    Hi Iduvall i change the carousel-horizontal-posts-content-slider.php file from line 49 where you find these lines:

    if($displayimage=="YES"){
    
    			 if (has_post_thumbnail( $post->ID ) ):
    $image = wp_get_attachment_image_src( get_post_thumbnail_id( $post->ID ),'thumbnail' );
    			endif; 
    
    $featured_img = "<img class='aligncenter wp-post-image' src='". $image[0] . "' " . $attributes . " />";
    
    $slider_gallery.= '<a href="'.$post_link.'">'.$featured_img.'</a>';
    		}

    i change line 53 and 57 to show the thumbnail version of the featured image.

    bye
    Maurizio

  3. mdehghani
    Member
    Posted 3 months ago #

    i tried the code a few times but didnt get any result.. am i missing sth??

Topic Closed

This topic has been closed to new replies.

About this Plugin

About this Topic

Tags