Viewing 6 posts - 1 through 6 (of 6 total)
  • Author
    Posts
  • #37744
    PHAUS
    Participant

    HI,

    I’m having some trouble with a table I’ve created to organize some content. The page is here: http://naphc2014.phius.org/schedule/draft-breakout-sessions/

    My problem is that I want the bolded names (ex: Sam Rashkin) on one line, and insert a line-break before the short non-bolded paragraph. Then another line break before the next set of bolded names, and again before the next paragraph.

    No matter what I do, the line breaks disappear once I’ve published the page, but they appear in the preview.

    Second, I’m wondering if you could advise which part of the CSS to tweak to give the table some padding. The text is uncomfortably close to the border.

    Many thanks!

    #37814
    Sakin
    Keymaster

    @PHAUS: It’s the table and you need to manage your content. For every line break you can add in <br /> code. See this tutorial http://www.w3schools.com/tags/tag_br.asp
    Alternatively, you can add css to make all bold text in table in separate line by adding in the following css in “Appearance => Theme Options => Custom CSS” box.

    .entry-content table strong {
        clear: both;
        display: block;
    }
    #37860
    PHAUS
    Participant

    Hi Sakin,

    Thanks! The CSS did help. <br /> does nothing. Or rather it works when I hit preview, but if I switch from Text editor back to Visual the code disappears. Very frustrating.

    A little more research shows it to be an issue with WP editor.

    Can you advise what CSS to use for adding padding? Best if it only affects this one table, instead of all tables on my site.

    THANK YOU!

    #37874
    Sakin
    Keymaster

    @PHAUS: You can add #post-556 for css just for this page.

    #post-556 .entry-content table strong {
        clear: both;
        display: block;
    }

    Where do you want to add padding?

    #37880
    PHAUS
    Participant

    Hi Sakin,

    I need padding on the left of the text inside each cell. So it’s not hugging the left wall.

    Thanks.

    #37884
    Sakin
    Keymaster

    @PHAUS: You can add the following css in “Appearance => Theme Options => Custom CSS” box.
    #post-556 .entry-content td { padding-left: 10px; }

Viewing 6 posts - 1 through 6 (of 6 total)
  • The topic ‘Spacing/Line Breaks within a table’ is closed to new replies.