How to insert a table into a WordPress post or page

--------------- Now playing: Why by Annie Lennox ---------------

Sometimes you may want to display some sort of data in a table on your WordPress blog. There are ways to import an Excel spreadsheet into a post, and here's a link to the Excel section of the WordPress Codex: http://wordpress.org/tags/excel

But sometimes Excel is overkill—or maybe you don't use Excel and just need a very simple table. You can accomplish this with the TinyMCE Advanced plugin.

The plugin has lots of other helpful features, too, one of which is that you can tell it to stop removing your <p> and <br> tags, as shown below. It's frustrating to format a post and then have your line breaks and paragraphs stripped out as soon as you save. Once you've installed the plugin, checking this option will save you some hair-tearing moments.

But on to the reason we're talking about this WordPress table plugin today. First you'll want to download the plugin from the link above. Save it somewhere on your computer where you can find it again.

Install it one of two ways: 1) by unzipping the folder and uploading it into your wp-content/plugins/ folder via your FTP program, or 2) by going to Plugins > New > Upload in your WordPress dashboard. Browse to its location on your hard drive and upload the unzipped file. Then be sure to activate the plugin with the Activate link under its name.

When you've done that, find the settings panel by going to Settings > TinyMCE Advanced in the left-hand column of your dashboard. You'll see something like this:

You can drag any of the options you'd like to have in your toolbar up to the shaded bars. One of them is Table, shown in the above screenshot. Drag this to one of the bars and click Save Changes.

Now, go back to the post where you want to insert the table. Click on the Insert Table icon, shown below.

In the box that pops up, choose how many columns and rows you need to have, like so:

You can also experiment with the padding, spacing, alignment, borders and other properties to suit your particular purpose. Then, once you click on Insert, you'll see the table in your post:

Doesn't look like much yet, but look at the next shot:

You click in the various fields to type in your text, and you add photos the same way as to a regular post. To delete a table, just click on its edge to select it and hit Delete on your keyboard or the far right button on the Table toolbar that you installed.

The Table toolbar buttons are also where you would go to edit a table after you've created it; just click on the table to make the icons usable. You can add and delete rows and columns, merge cells, change properties, etc.

So there you go—install the plugin and play with it! Be sure to check out its other features as well.

{ 3 comments }

Kelli @ Fight Cellulite April 27, 2011 at 5:04 am

I was trying to make a table last week for four pictures and some text I was trying to do for some workout procession still images. Had a difficult time. This post totally helps me out. Especially since I suck at Excel (used to be kind of good at it back in the day – but now – forget about it hahaha).

Speaking of plugins, I have a question that’s off-topic: How many plugins are too many on a site? I know my must-haves, but neat ones like this one and some others, I was just curious what’s too much. And would having too many plugins ever effect the load time of a website? Just curious for future reference :)

Laura April 28, 2011 at 12:55 pm

Glad the post helped! There is another option I meant to include – a plugin called Google Doc Embedder, helpful for embedding a variety of other formats into a post. Here’s the link: http://wordpress.org/extend/plugins/google-document-embedder/

As for plugins, I don’t know if there’s an optimum number of plugins, but it’s true you need to be careful not to overdo it. They can slow down a site because many will load even if they aren’t related to the particular page the visitor is on. It appears that many recommendations are to keep the number under 10, but that can be tough. I would definitely try to keep it less than 20 if possible, and 30 at max. There are people running more than that who claim they aren’t experiencing slow-downs, but that’s definitely overkill. It’s good to check if what you want the plugin for can be accomplished with hard-coding.

I have about 20 running on this blog, but I am ashamed to admit I have not tested to see if getting rid of some would speed up my site. It’s on my list…

Kelli @ FIght Cellulite April 29, 2011 at 2:29 pm

Thanks Laura for posting the extra option! I just counted and have about 20 now too with the addition of the TinyMCE Advanced Plugin.

Thanks for this tip too! – “It’s good to check if what you want the plugin for can be accomplished with hard-coding.”

Comments on this entry are closed.

Previous post:

Next post: