• Resolved oichinokata

    (@oichinokata)


    Dear Themeisle and odeinwp,

    Thank you for developing the great plugin.
    I’m making a function for ‘feedzy_thumb_output’ filter.
    It rewrites $contentThumb, then it displays the thumbnail by img tag in my functions.php.
    The functions needs width/height property for img tag, but original $contentThumb doesn’t include them as style.
    The version 2.8 had them as style, but 3.0.7 doesn’t have.
    Could you restore the style at the next version?

    Here is a sample patch code.

    --- feedzy-rss-feeds-3.0.7/includes/abstract/feedzy-rss-feeds-admin-abstract.php	2017-01-27 10:37:28.000000000 +0900
    +++ feedzy-rss-feeds/includes/abstract/feedzy-rss-feeds-admin-abstract.php	2017-02-04 10:15:28.405339299 +0900
    @@ -504,10 +504,10 @@
     			if ( ( ! empty( $theThumbnail ) && $sc['thumb'] == 'auto' ) || $sc['thumb'] == 'yes' ) {
     				if ( ! empty( $theThumbnail ) ) {
     					$theThumbnail = $this->feedzy_image_encode( $theThumbnail );
    -					$contentThumb .= '<span class="fetched" style="background-image:  url(' . $theThumbnail . ');" alt="' . $item->get_title() . '"></span>';
    +					$contentThumb .= '<span class="fetched" style="width:' . $sizes['width'] . 'px; height:' . $sizes['height'] . 'px; background-image:  url(' . $theThumbnail . ');" alt="' . $item->get_title() . '"></span>';
     				}
     				if ( $sc['thumb'] == 'yes' ) {
    -					$contentThumb .= '<span class="default" style="background-image:url(' . $sc['default'] . ');" alt="' . $item->get_title() . '"></span>';
    +					$contentThumb .= '<span class="default" style="width:' . $sizes['width'] . 'px; height:' . $sizes['height'] . 'px; background-image:url(' . $sc['default'] . ');" alt="' . $item->get_title() . '"></span>';
     				}
     			}

    Could check it?

    Kind Regards,
    Oichinokata

Viewing 2 replies - 1 through 2 (of 2 total)
  • Plugin Author Themeisle

    (@themeisle)

    Hey @oichinokata,

    Sorry for the delay, i have added the sizes as parameter to the feedzy_thumb_output in order for you to properly edit it.

    Let me know if you need anything else.

    Thread Starter oichinokata

    (@oichinokata)

    Dear Themeisle,

    You are smart! Thank you cool update!

    Kind Regards,
    Oichinokata

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘Thumbnail sizes are missing (including patch code)’ is closed to new replies.