Viewing 4 posts - 1 through 4 (of 4 total)
  • Author
  • #17609

    I’ve seen this question asked a few different ways in this forum, so I figured out from those posts how to make portfolio and blog posts show up under latest posts and popular posts in the Combo Widget (though I’m not sure it’s the best way…), but I can’t figure out how to make that work with the latest comments.

    For the latest posts and most popular posts, I opened up class-frameworks-widget.php and basically added a second ‘avia_get_post_list’ to call the portfolio posts and left the blog posts intact, rather than replacing it. When I change how many I want shown in the widget area, it will show that many of EACH type.

    echo '<div class="tab first_tab widget_tab_popular"><span>'.__('Popular', 'avia_framework').'</span></div>';
    echo "<div class='tab_content'>";
    echo "</div>";

    echo '<div class="tab widget_tab_recent"><span>'.__('Recent', 'avia_framework').'</span></div>';
    echo "<div class='tab_content'>";
    avia_get_post_list('post_type=portfolio&showposts='. $posts .'&orderby=post_date&order=asc');
    avia_get_post_list('showposts='. $posts .'&orderby=post_date&order=desc');
    echo "</div>";

    The problem is… I don’t really know what I’m doing, so I’m not sure if that is the best way to handle it, and … I don’t know how to produce the same effect with the comments section. Any ideas?


    Err… so minutes after I posted this, the comments from the portfolio entries started showing up in the box. So maybe it already works like that and it was just torturing me for awhile?

    I would still like to know if my solutions for the recent and popular posts is a good one or not. I know it’s working… but I don’t know enough about coding to know if it will break the way something else is supposed to work later down the line. :)

    Thanks for a great theme!


    Hey cameljok,

    That sounds correct. Just make sure to save a backup of the file you edited so when you update the theme or framework you can easily re-apply your change :)




    Ok, thanks! :)

Viewing 4 posts - 1 through 4 (of 4 total)

The topic ‘Portfolio AND Blog Posts in Combo Widget’ is closed to new replies.