Tables in Movable Type entries.

Thought I’d post a quick tip on this, since I couldn’t find it published anywhere else: If you’ve got a table you want to put inside an MT entry, you’ve got to put all the HTML table code on a single line. Otherwise, MT will add <br /> tags after every line — and when the page is published, these line breaks will add up to a huge, inexplicable white space just above the table.

Tables in Movable Type entries.

3 thoughts on “Tables in Movable Type entries.

  1. I think the cleaner approach is to turn off the “Add line breaks” option in that entry’s formatting. Doing so will require you to add P or BR tags to the rest of the content in that entry manually, but it’s cleaner than funking up the table (I do this for the polls on Birdhouse, so the PHP code they include doesn’t get HTML-ized).

  2. I’ve been searching all over this morning for a reason for that inexplicable white space – many thanks!

    Scot has a good point about not wanting to mung the table code, but it seems like the lesser of two evils in my situation (creating a weblog/magazine for use by literary folk who are even less web-savvy than I am).

    This should be just a temporary fix; I think my path forward is to eschew tables and try CSS and DIVs, maybe?

  3. Lots of CSS designers try to avoid using tables at all, but I think that’s overkill. Sure, CSS can do layout better than tables can. But when you’ve got tabular data, you should put it in tables!

Comments are closed.