WordPress.org

Ready to get started?Download WordPress

Forums

[resolved] Displa latest posts in a 2 column grid (5 posts)

  1. bngari
    Member
    Posted 1 year ago #

    I am creating a WordPress theme and I want the latest posts to be displayed in a 2 column grid (if the maximum posts are 10, then it should display 5 rows and 2 columns.) Kindly assist.

    Thanks in advance.

  2. esmi
    Forum Moderator
    Posted 1 year ago #

    This would be handled using pure CSS. Do you know how to use CSS?

  3. bngari
    Member
    Posted 1 year ago #

    Yes I know css, it is how tostructure the php code that's the problem.

  4. esmi
    Forum Moderator
    Posted 1 year ago #

    You don't need any PHP to do this. Just set each post's enclosing div (or similar) element to around 50% and float it left.

  5. bngari
    Member
    Posted 11 months ago #

    Thanks esmi, it worked.

Topic Closed

This topic has been closed to new replies.

About this Topic