• Skip to primary navigation
  • Skip to main content
  • Skip to primary sidebar
Appfinite

Appfinite

Premium WordPress Themes for The Genesis Framework

  • Themes
  • Blog
  • Tutorials and Resources
  • Forums
  • Contact Us

Reply To: Changing the Order of the Posts

Home › Community Forums › Agile Theme Support › Changing the Order of the Posts › Reply To: Changing the Order of the Posts

April 27, 2012 at 9:42 pm #881
Wes
Moderator

Currently the max-width for the #wrap is 1250px, which would fit about 6 images in a row. You could increase or decrease this number if you wanted to, but it will change the width of your entire site as well.

Another option – In my other themes, I have code that adds a clear: both; after a certain number of posts…….in other words, it does exactly what you are asking for, and you control at which number/post everything starts over and creates a new row.

You can add this to your home.php file and it should work (adjust the loop counter number if needed) –


// Remove standard loop
remove_action('genesis_loop', 'genesis_do_loop');

// Clear float using genesis_custom_loop() $loop_counter variable
// Outputs clearing div after every 5 posts
// $loop_counter is incremented after this function is run
add_action('genesis_after_post', 'portfolio_after_post');
function portfolio_after_post() {
    global $loop_counter;
    
    if ( $loop_counter == 4 ) {
        $loop_counter = -1;
        echo '<div class="clear"></div>';
    }
}
}*/

Primary Sidebar

Search Forums

Affiliate Program

Looking to earn some money? Join our Affiliate program and earn 35% of every sale you refer. Top referrers earn 40-50%.

Join Now →

The Genesis Framework

All of our themes are designed for the Genesis Framework. You will need to purchase Genesis in order to use any of our themes.

Purchase Genesis

Hire a Web Developer

Need help setting up or customizing your website?

Contact Us →

Search Full Site

  • Buy Genesis!
  • Shopping Cart
  • Themes
  • My Account
  • Support Forums
  • Tutorials and Resources
  • Privacy Policy
  • Contact Us
  • Follow Us on Twitter

Copyright © 2022 · Appfinite · Built With The Genesis Framework