How to make blog posts display as 3 column layout

Community Forums Forums Design Tips and Tricks How to make blog posts display as 3 column layout

This topic is: not resolved

This topic contains 3 replies, has 3 voices, and was last updated by  Sridhar Katakam 8 months, 1 week ago.

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

    pinar
    Member
    Post count: 3

    I’m using the Minimum Pro and on the homepage two blog posts show up side by side (see the URL).

    How can I turn that two column layout (on homepage only) to three column so that it will show three blog posts?

    http://my.studiopress.com/themes/minimum/#demo-full
    #80653

    genwrock
    Member
    Post count: 523

    Add the following code in functions.php file

    add_filter('genesis_grid_loop_post_class', 'threeColGridClass');
    function threeColGridClass(array $grid_classes){
      global $_genesis_loop_args, $wp_query;
      $new_classes = array();
      $new_classes[] = 'one-third';
      if(($wp_query->current_post + 1)  % 3 == 1){
        $new_classes[] = 'first';
      }
      return $new_classes;
    }

    Working as a freelancer & helping the people on forum | Chinmoy @ PWD | Please Follow Me on Twitter If I’ve helped.

    #80663

    pinar
    Member
    Post count: 3

    Ok that worked like a charm. Thanks a lot!

    #80734

    Sridhar Katakam
    Participant
    Post count: 1003
Viewing 4 posts - 1 through 4 (of 4 total)

You must be logged in to reply to this topic.