I currently have all the posts displayed in one column:
1
2
3
...
I'd like to achieve something similar:
1
23
4
56
...
does anyone have any ideas of how I could do this? is it possible? thank you so much in advance :)
right now I have:
<?php if( $wp_query->current_post <= 0 ) : ?>
code for the first one column post
<?php else : ?>
the rest of the posts styled in columns
<?php endif; ?>
Just use a counter like this:
The solution I found for this problem was using the $wp_query->current_post of a default loop, in a filter function added to
functions.php
file in the theme, when post's div ispost_class()
The example above restricts this to posts on the home page or posts page; otherwise, you need to change the coditional tag
is_home()
to something else.