What’s New in Revisions for WordPress 3.6

Getting to the revisions screen is easier than ever with a new link in the Publish meta box.
Getting to the revisions screen is easier than ever with a new link in the Publish meta box.

The All New Revisions UI and numerous bug fixes!

The revisions system in WordPress has been given a complete overhaul in the new (upcoming) Version 3.6 of  WordPress.  The new version of revisions patches several longstanding bugs and issues with the revisions system and introduces a slick new user interface for viewing and comparing revisions.

The new interface uses a scrollbar and features two modes – a single handle mode where each revision is displayed indicating whats changed in that revision, and a two handled mode where users can compare any two revisions stored in the system and see whats changed between them. Significant effort was put into making the process as fast as possible, and the JavaScript interface means it’s quick to find the revision you are looking for and restore it.

The revisions interface focuses on two primary use cases: undoing mistakes by finding the last correct revisions, and reviewing changes as part of an editorial workflow. To improve these uses, a completely new UI was created, and numerous bugs were fixed.

Highlights of  new Revisions features for WordPress 3.6

  • Revisions Rewrite using Backbone.js – this complete iStock_000010243941XSmall-200x300reworking of the way users interact with the stored revisions combines immediate screen updates with a scroller that makes exploring revisions quick and easy. Massive effort was put into refining, testing and improving the system – it allows rapid scrobbing through up to hundreds of revisions. Quickly locate the revision you need and restore it; also allows comparing of any two revisions – no more clicking and waiting to see a comparison, just scroll through to find the revision you need – #23497
  • Store a copy of the current post data as a revision – keep the revisions data current – previously only the previous save was stored as a revision, now the current save is stored as a revision. #16215
  • Filter to override WP_POST_REVISIONS (or define it later) – allows you to disable or set the number of revisions allowed on a per site basis setting on a multisite install – #22289
  • Pass post ID to post revision field filter – #19932


What’s Fixed in Revisions for WordPress version 3.6

Previous versions of WordPress had several problems with the revisions system that have been corrected in the 3.6 release. The following significant bugs were addressed in this release cycle:

  • Duplicate autosave/revisions clutter the database (because revisions are saved even if nothing has changed) – #9843
  • Extra revision created every time a new post is inserted – by the first time you published a post, there were already two revisions – #24708
  • Restoring post revisions does not update _edit_last – now the revisions system tracks who last restored a post revision – #20982
  • Post Revision history displays the incorrect author – the old system stored a revision before updating a post, yielding bad data that 3.6 corrects. #16215


Contributing to WordPress core

Recently, I started contributing to WordPress core. I’ve decided to hone my WordPress skills beyond writing WordPress plugins.

Contributing code patches to core is exciting because they get scrutinized by some top notch programmers I admire, and if accepted, get used directly in WordPress. I’ve also been testing bugs and other people’s fixes when I can, but creating patches is the most part exciting so far! My first patch was tiny and accepted without a change, most of the rest have been more complex and needed little fine tuning. Along the way I’m learning more about the WordPress core than any normal person needs to know.

Here are some patches I’ve contributed recently:

  • #22919 – my first, patch, accepted and committed by nacin. grin:). fixed a javascript type mismatch
  • #22606 – ‘select a file’ link doesn’t work from keyboard, accessibility issues – added javascript fix
  • #22933 – tabbing out of text edit area went to wrong field, fixed bug in code
  • #21334 – fixed accessibility issue with quick edit panel, two possible patches
  • #23120 – fixed issue with unclear/no confirmation on widget save/reorder
  • #22896 – eliminate possibility of removing bundled jQuery when in Dashboard
  • #22917 – user/site count not updating (immediately) after adding/removing user/site(s)

It took me a little bit of time to get the local setup for debugging and coding WordPress core, but mainly because I haven’t done anything quite like that before. Now that everything is set up locally, I can work on fixing bugs or testing fixes quickly and efficiently. When I find a bug I can fix, creating the patch file is as simple as a command line command away, especially as outlined in Mark Jaquith’s Toolbox.

Enforcing _blank target on external links

When training new clients on how to edit their own websites in wordpress, I often mention the convention of ‘targeting blank’ when linking to another website. Adding the ‘target=”_blank”‘ tag to the link opens a new window when the user clicks the link, leaving the client website open in the background . Still, I know clients will forget this so I often add a little JavaScript code to make sure the links are always set to target blank:

Since I know all my wordpress sites include jQuery, I use that library to make the call as compact as possible:

$(document).ready(function() {

what does it do? it finds all links that start with http:, then filters out (not) those links that go to the CLIENTDOMAIN.COM (their domain name), then it sets the ‘target’ attribute to ‘_blank’, linking all external links on the

Google DNS Hacked! at my local ISP

Update: as of 10:50 DNS am is restored for google.com.

Its happened, the internet is dead!

Well, nearly dead anyway – today I was suddenly unable to access Google’s Analytics service around 10:10am MST. At first i thought it was a general failure, but other sites were still working. So I issued a whois command, clearly showing google’s dns has been hacked – at least at my ISP’s DNS server –

whois google.com

Whois Server Version 2.0

Domain names in the .com and .net domains can now be registered
with many different competing registrars. Go to http://www.internic.net
for detailed information.


To single out one record, look it up with “xxx”, where xxx is one of the
of the records displayed above. If the records are the same, look them up
with “=xxx” to receive a full display for each record.

>>> Last update of whois database: Thu, 14 Jan 2010 17:17:37 UTC <<<

NOTICE: The expiration date displayed in this record is the date the
registrar’s sponsorship of the domain name registration in the registry is
currently set to expire. This date does not necessarily reflect the expiration
date of the domain name registrant’s agreement with the sponsoring
registrar.  Users may consult the sponsoring registrar’s Whois database to
view the registrar’s reported date of expiration for this registration.

TERMS OF USE: You are not authorized to access or query our Whois
database through the use of electronic processes that are high-volume and
automated except as reasonably necessary to register domain names or
modify existing registrations; the Data in VeriSign Global Registry
Services’ (“VeriSign”) Whois database is provided by VeriSign for
information purposes only, and to assist persons in obtaining information
about or related to a domain name registration record. VeriSign does not
guarantee its accuracy. By submitting a Whois query, you agree to abide
by the following terms of use: You agree that you may use this Data only
for lawful purposes and that under no circumstances will you use this Data
to: (1) allow, enable, or otherwise support the transmission of mass
unsolicited, commercial advertising or solicitations via e-mail, telephone,
or facsimile; or (2) enable high volume, automated, electronic processes
that apply to VeriSign (or its computer systems). The compilation,
repackaging, dissemination or other use of this Data is expressly
prohibited without the prior written consent of VeriSign. You agree not to
use electronic processes that are automated and high-volume to access or
query the Whois database except as reasonably necessary to register
domain names or modify existing registrations. VeriSign reserves the right
to restrict your access to the Whois database in its sole discretion to ensure
operational stability.  VeriSign may restrict or terminate your access to the
Whois database for failure to abide by these terms of use. VeriSign
reserves the right to modify these terms at any time.

The Registry database contains ONLY .COM, .NET, .EDU domains and

Web Development Enters a New Era

Web publishing platforms such as WordPress have reached a maturity level that allows developers to deploy robust websites managed and maintained by clients. The developers role becomes focused on design and implementation, while content development is client driven. Modern libraries like jQuery and the WordPress plugin mechanism mean that ideas and projects that used to take days or weeks to implement and debug now take just minutes orhours to install and configure.