» Managing Post and Page Revisions in Wordpress
May 6th, 2009 Sammy RussoWith the release of Wordpress 2.6 a new feature was added that tracks and retains all previous versions or revisons to Wordpress Posts and Pages. Many think this is a great feature and can be very useful. In the building of California Whitewater I used the revision feature several times to roll back to a previous version.
A Valid Problem With Post Revisions
If you sift through the Wordpress Support Forum you will find many Wordpress users griping about the revison feature because it tracks all revisions. If you have a 100 posts and you edit each post 2 or 3 times you will get an additional 200 – 300 records in your MySQL database. For bigger sites or blogs do the math. This makes for an unruly database size.
Being that California Whitewater took us several months to build and with 4 people making content edits over the course of 4 months we had an extra 2600 records of revisons in the database. We build the site in a development space and when it was time to move the site to the live server I couldn’t move the database in one shot… I had to split it into 4 parts, do a find and replace on each part to update the URL and image paths and then move the DB.
Before moving I did look through the forums for help on how to clean up the database but I wasn’t comfortable with doing a global delete of all revisions in the MySQL database to reduce the size of the DB.
Deleting Your Post Revisions
Database Cleanup
Now that site is live and all is good, I went back to the development space for California Whitewater and ran this MySQL command to clear out all the revisions. I did it on the dev site to test the process and ensure I wouldn’t break anything on the live site if something were to go very wrong.
Step 1. Back Up Your Database.
- You can follow the steps outlined here in Simple Maintenance to run a backup.
- You can also install a WP-Plugin like WP-DB-Backup or try anyone of the Backup Tools.
Step 2. Run a delete command in PHP My Admin
- Open PHP My Admin
- Select the database you wish to clean up
- Click the SQL Tab in the top horizontal navigation
- Copy and Paste this Command:
DELETE FROM wp_posts WHERE post_type = "revision";
Step 3. Test Your Site to make sure nothing broke in the process
Use a Post Revision Plugin
There a several Post Revision Plugins in the Wordpress Extend section. The one I downloaded “Revision Control” is great and has become part of my personal collection of plugins I use on all sites.
What I like about Revision Control is that you can enable or disable revisions on global bases as well as set the number of revisions to keep. I set Revision Control to retain the last 5 versions of both pages and posts. You can also control the revision process on a page-by-page or post-by-post basis.
There you have it.. an easy way to delete post revisions from the database as well as a great plugin to control revisions.
» My Favorite SEO Plugins
March 12th, 2009 Sammy RussoI’ve been building CMS Websites and Blogs using Wordpress since 2006. In that time I’ve compiled my set of base plugins that I use for every new installation.
Out of my base plugins, 3 of those plugins are for search engine optimization or SEO. They are…
I use SEO Title Tag to control.. bet you’ll never guess.. the Title Tag. I sometimes even use it to control the main headline of pages. I could use Headspace 2 to control the title tag but what happens is it rewrites the Post title which I don’t necessarily like so I chose to use SEO Title Tag instead.
I use Headspace 2 to control meta description, meta keyword tags, adding extra stylesheets and integrating Google Webmaster Tools. This tool has so many useful modules or facets to it… you really just need to download it and start experimenting.
And last but not least Google XML Sitemap plugin to automatically generate my sitemaps also submit them to Google, MSN & Yahoo.
So what are you’re favorite SEO Plugins for Wordpress.
» Twitter Tools Plugin
March 11th, 2009 Sammy RussoThis is a very nice little plugin… Twitter Tools by Alex King.
My friend Jamie suggested I check out Twitter Tools so I did. So far the only feature I have tried / tested was “Creating a Tweet from a Blog Post.”
Very cool. I like that there is a check box in the post editor that allows to pick and chose which posts get published as tweets.
Other features include the inverse… creating blog posts from tweets. The Twitter Tools plugin can also create Tweet Digests… daily & weekly.
I myself am just starting to dive into the Twitter Platform.. but rest assured that Twitter isn’t going away, so I better start figuring things out now and so should you.
» Wordpress Automatic Upgrade
February 19th, 2009 Sammy RussoWordpress Automatic Upgrade is a must have if you manage multiple installations of Wordpress.
I’ve been using Wordpress Automatic Upgrade for several months now. I stumbled onto it when I was talking to a developer friend of mine about how to automate the upgrade process as I manage approximately 20 installations of Wordpress.
This plugin does it all. Packages backups for both the database and all files and provides them for download. It installs a complete new set of files from WP, cleans up all the old stuff and you’re done.
It literally takes 5 minutes to completely backup and upgrade each installation of Wordpress.
» ShareThis! Social Bookmarking Widget
July 30th, 2008 Sammy Russo
The buzz across the web and all the Search Engine Conferences for the last couple of years has been social media marketing or SMM. The social media platform can be a very powerful tool for your blog, feed or website.
My favorite social media plugin is ShareThis! for Wordpress. ShareThis! actually started (and still is) a widget that can be customized to your liking and placed on your website or blog. With Wordpress you still have to go to the web and register for a ShareThis! Account and the plugin makes it easy to include the button in your content.
I like ShareThis! for a few reasons…
- It allows for interaction with all the top social media platforms like Facebook, Twitter, Digg, Stumble Upon, Technorati etc.
- It also has an email a friend function.
- Reporting features in the ShareThis! web panel.
- Compact.. it doesn’t add 25 little buttons to your content.
- Within Worpress.. very easy to manually configure where you want your ShareThis! Button to be placed if you don’t like the auto placement.
» A Great New Anti Spam Bot Plugin
June 7th, 2008 Sammy RussoI came across a great new plugin this morning.. I’ve been looking for this exact plugin for a while now. The plugin is called is_human() by Nick Berlette. With one tiny snippet of code placed into the comments.php file and you have catpcha security integrated into you site. Upon activation it automatically embeds it self in your Wordpress Registration page.
I have a blog called Tehachapi Daily which is completely open to the community to post to the site. They are granted contributor level access immediately upon registration and get worried sometimes about all the spam registers I get. Now with is_human(), I’ve got Catpha security.
Thanks Nick for developing this new plugin.
