WordPress.org

Ready to get started?Download WordPress

Forums

Help showing page of posts in 4 columns (4 posts)

  1. lewispaulsims
    Member
    Posted 1 year ago #

    I'm a noob to PHP and WP. Mostly an HTML/CSS guy. I've got a site set up more or less the way I need it but for one page. I have a page showing entire posts by a specific category, but I need to show them in four columns. I've got the first part, but as for the second part, the closest I have gotten is some CSS that looks messed up and probably won't work in IE. Any help?

    Here is the page in question:
    http://www.chrisoconnordesign.com/midcap/transactions-abl/

  2. WPyogi
    Volunteer Moderator
    Posted 1 year ago #

    You might want to start with the mark-up errors:

    http://validator.w3.org/check?uri=http%3A%2F%2Fwww.chrisoconnordesign.com%2Fmidcap%2Ftransactions-abl%2F&charset=%28detect+automatically%29&doctype=Inline&group=0

    It also looks like there is a stylesheet missing the extension...using View Source shows it close to the top of the page.

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

    a:
    styling posts into columns is mainly a html/css issue;

    b:
    general approach: give each post div a fixed width, and a float:left - as you have done with your column inline styles (try to avoid inline styles, as they are much harder to debug with tools such as Firefox' web developer add-on);
    in the loop, add a clear:left to each first, fifth,... post div, possibly by adding a corresponding css class to the div;

    c:
    if you really want to dump the posts into columns, you need a special loop structure - for example see my post - but this is usually not necessary.

    you can paste the full code of your template into a pastebin and post the link to it here - HOW-TO - ad someone might be able to make some suggestions.

  4. lewispaulsims
    Member
    Posted 1 year ago #

    WPyogi, It would probably help if I didn't change the page before/while people are responding. Sorry, pretty sleepless here.

    alchymyth, thank you.

Topic Closed

This topic has been closed to new replies.

About this Topic