• The plugin is using the thumbnail size 150 by 150 from my media settings theme thumbnail size. This works great for the rest of my website, but I want to change the thumbnail size of the related posts to 90 by 90 and keep my themes thumbnail size the same, is their any way I can edit this code or any other code to get my desired results?

    The code for the plugin:

    /* Calculating sizes */
    if ( $thsource == ‘custom-field’ ) {
    $debug .= ‘Custom sizes;’;
    $width = get_option( ‘relpoststh_customwidth’, $this->custom_width );
    $height = get_option( ‘relpoststh_customheight’, $this->custom_height );
    }
    else { // post-thumbnails source
    if ( $poststhname == ‘thumbnail’ || $poststhname == ‘medium’ || $poststhname == ‘large’ ) { // get thumbnail size for basic sizes
    $debug .= ‘Basic sizes;’;
    $width = get_option( “{$poststhname}_size_w” );
    $height = get_option( “{$poststhname}_size_h” );
    }
    elseif ( current_theme_supports( ‘post-thumbnails’ ) ) { // get sizes for theme supported thumbnails
    global $_wp_additional_image_sizes;
    if ( isset( $_wp_additional_image_sizes[ $poststhname ] ) ) {
    $debug .= ‘Additional sizes;’;
    $width = $_wp_additional_image_sizes[ $poststhname ][ ‘width’ ];
    $height = $_wp_additional_image_sizes[ $poststhname ][ ‘height’ ];
    }
    else
    $debug .= ‘No additional sizes;’;
    }
    }
    // displaying square if one size is not cropping
    if ( $height == 9999 )
    $height = $width;
    if ( $width == 9999 )
    $width = $height;
    // theme is not supporting but settings were not changed
    if ( empty( $width ) ) {
    $debug .= ‘Using default width;’;
    $width = get_option( “thumbnail_size_w” );
    }
    if ( empty( $height ) ) {
    $debug .= ‘Using default height;’;
    $height = get_option( “thumbnail_size_h” );
    }
    $debug .= ‘Got sizes ‘.$width.’x’.$height.’;’;
    // rendering related posts HTML
    if ( $show_top )
    $output .= stripslashes( get_option( ‘relpoststh_top_text’, $this->top_text ) );
    $relpoststh_output_style = get_option( ‘relpoststh_output_style’, $this->output_style );
    $relpoststh_cleanhtml = get_option( ‘relpoststh_cleanhtml’, 0 );
    $text_height = get_option( ‘relpoststh_textblockheight’, $this->text_block_height );
    if ($relpoststh_output_style == ‘list’) {
    $output .= ‘<ul id=”related_posts_thumbnails”‘;
    if (!$relpoststh_cleanhtml)
    $output .= ‘ style=”list-style-type:none; list-style-position: inside; padding: 0; margin:0″‘;
    $output .= ‘>’;
    }
    else

Viewing 5 replies - 16 through 20 (of 20 total)
Viewing 5 replies - 16 through 20 (of 20 total)
  • The topic ‘Related Posts Thumbnails custom thumbnail size, quick change’ is closed to new replies.