Centering a table?

  • Author
  • #259881


    Hi guys,

    I’m new here and previously to center to images side by side I would use a table like this,


    However, this doesn’t seem to work on Is there a way around it?




    To center the whole table within the post:
    <table align="center"><tr><td></td>/tr></table>
    To center the cell contents:
    <td align="center"></td>


    Moderator Emeritus

    Serendipity! That’s exactly what I wanted to know!
    Thank you.


    Moderator Emeritus

    Oh, well. It doesn’t seem to work. Likely I’m still doing something wrong.


    @1tess: Perhaps you didn’t apply wpvstp’s suggestion correctly. Let me try to clarify: instead of
    in the beginning, you put
    <table align="center">


    Moderator Emeritus

    html always makes me stupid. I was making it too complicated: it works perfectly.
    I’m making a table with data in the cells and only now read the original post. It’s easier in WP to center 2 or more pictures without using a table:
    Insert pictures into the post with “align none” for each one. Once they are visible in the editor, select both pictures (highlight), then use the column alignment tool in the visual editor to center them. You may want to add space between the pictures by going back to “Advanced Settings” to add horizontal space between them.


    Moderator Emeritus


    Thank you. I got it!
    I got so inspired with the success that I even figured out how to add colors!



    You can add pretty much all table code as shown in the examples here
    But beware, if the table get’s too sophisticated and you miss a tag here or there it can mess up the whole thing.

The topic ‘Centering a table?’ is closed to new replies.