WordPress.org

Ready to get started?Download WordPress

Forums

[resolved] Show posts in two columns - how to do it simple? (8 posts)

  1. tymonbumba
    Member
    Posted 1 year ago #

    Hi guys,

    I know, there is lot of post how to do it, but I am a really new user in wordpress and my language skills are maybe not enough.

    So, my question is really simple... and my case is:
    I have website on wordpress, where my horizontal menu is made by single pages an one of the menu item is category. When I click on this category button, it shows me posts in one column.
    so what i need is to show these posts in two columns like this:

    1 / 2
    3 / 4
    5 / 6

    Can anyone send me some code and instruction (some like for totaly dummies), where and what i should write and in which file (index.php or content.php,....etc)

    Lot of thanks to everyone who has any idea how to do it :)

    [No bumping. If it's that urgent, consider hiring someone.]

  2. vtxyzzy
    Member
    Posted 1 year ago #

    Exactly how to do that depends on your theme. If you are using a free theme, post a link to your site here and someone may be able to help. If you are using a paid theme, you should contact the theme supplier.

  3. tymonbumba
    Member
    Posted 1 year ago #

    Hi, thank you for your reply :)

    I'm using theme generated by Artisteer...

  4. alchymyth
    The Sweeper & Moderator
    Posted 1 year ago #

    the simplest is to add a fixed width (just less than half of the existing space) to the post div, and float it left with a small right margin.
    this might work wiht just editing style.css but has limitations.

    next better step is to add a selective css class to all posts 'on the left' to be able to add differnt margins and a clear:both; to help with posts of different heights ...
    for this you need to edit the posts template.

  5. vtxyzzy
    Member
    Posted 1 year ago #

    Try adding this to the end of style.css:

    div.art-post { width: 48%; float: left; }
  6. tymonbumba
    Member
    Posted 1 year ago #

    vtxyzzy: that is great! working, but for all pages... I need it just for one of them (posts)... I try to do it as alchymyth wrote

    Many thanks to booth of you :)

  7. tymonbumba
    Member
    Posted 1 year ago #

    Solved 8-) ... I added

    <style>
    div.art-post { width: 48%; float: left; }
    </style>

    into the file content.php and it working just right there, where I want

    Thank you guys!

  8. vtxyzzy
    Member
    Posted 1 year ago #

    Please use the dropdown on the right to mark this topic 'Resolved' so that anyone else with this question can see that there is a solution.

Topic Closed

This topic has been closed to new replies.

About this Topic