WordPress.org

Ready to get started?Download WordPress

Forums

WordPress.com Popular Posts
Images are not optimized (3 posts)

  1. Rajesh Namase
    Member
    Posted 1 year ago #

    Images are resized using CSS which is not a proper method, any solution to optimize images?

    http://wordpress.org/extend/plugins/wordpresscom-popular-posts/

  2. orangpelupa
    Member
    Posted 1 year ago #

    i made this modification into the wppp.php to be like this

    if ( has_post_thumbnail( $post['post_id'] ) ) {
    						$replace['%post_thumbnail%'] = get_the_post_thumbnail(
    							$post['post_id'], $instance['thumbnail_size']
    						);

    that make the plugin able to crawl ANY post_thumbnail sizes that you have.

    call it like this

    <?php if (function_exists('WPPP_show_popular_posts')) WPPP_show_popular_posts("number=4&days=1&exclude=26101,26869&format=<a href='%post_permalink%' title='%post_title_attribute%'>%post_thumbnail%%post_title%</a>&thumbnail_size=new-depan-thumb"); ?>

    so the "thumbail_size" is not accepting width/heigh in pixel but accepting post_thumbnail name that supported by your theme.

    in my case, its called new-depan-thumb

  3. jayo
    Member
    Posted 8 months ago #

    This didnt work for me. I call popular posts via sidebar Widget... how do you change the widget with a different image size, which is defined in functions.php?

Topic Closed

This topic has been closed to new replies.

About this Plugin

About this Topic