Drupal core

Drupal Gotchya: Cache_get() Returns Expired Items

cache_get() returns $cache objects even if the cached item is stale (expired). The cached data will not be rebuilt every hour in the following example:
<?php
/**
* Builds complicated data for the monkey grip.
*/
function custom_monkey_grip_data() {
 
// Return the cached data
 
$cache = cache_get('custom:monkey_grip');
  if (!
$cache) {
   
// Some expensive processing to build the data.
   
$data = complicated_recursion_and_loops_on_lots_of_data();
   
   
// Cache the data and rebuild it every hour
   
$expire = time() + (60 * 60);
   
cache_set('custom:monkey_grip', $data, 'cache', $expire);
  }
  else {
   
$data = $cache->data;
  }
  return
$data;
}
?>

Vertical Tabs In Drupal 7 Core! How Open Source Does Usability – The Process

Vertical tabs are finally in Drupal core!

Screenshot of vertical tabs on an 'Article Edit' page in Drupal 7.
Screenshot of vertical tabs on an 'Article Edit' page in Drupal 7.

A week ago Angie "webchick" Byron committed a large patch from #323112 Vertical Tabs to Drupal 7 core. This change is quite possibly the most significant usability enhancement to Drupal 7 to date. Two of the three formal usability tests did usability testing with vertical tabs and reported positively.

Screenshot of a 'Story Edit' page in Drupal 6, before vertical tabs.
Screenshot of a 'Story Edit' page in Drupal 6, before vertical tabs.

UPDATE: Rob Loach has created a patch to implement vertical tabs on the node-type form.

UPDATE: See other issues about vertical tabs in Drupal core .

What is more interesting about this however, is the process, time and effort that it took to get this change into Drupal core. It all started over a year ago, well before DrupalCon Boston 2008 even before Drupal 6 had a stable release. The discussion around part of that patch goes back as far as November 2007! Along the way countless people have been involved in many discussions, worked on heaps of mockups, lots of prototypes, and loads of code.

Improving Node Forms With Vertical Tabs

Vertical Tabs module by Dmitri Gaskin is a Drupal module-ification of prototype work I did for the usability of Drupal's node forms, and was inspired partly by ideas in the discussion and design process of Views 2 UI – which was all part of my Season of Usability project. Vertical Tabs module in Drupal 6

Vote For DrupalCon Sessions

Unexpectedly, it appears I will probably be able to attend DrupalCon DC 2009. So I have been working frantically to get my session proposals in. Here they are; Make sure you review other recent session proposals which don't get a lot of eyes or votes since they are on the last page.

AJAX pagers for Drupal 7

One of the many great things about working at CivicActions is that we get a stipend for work we do for the community. This month I decided to use some of my stipend time to code up a proposed solution for Drupal core for dynamically loading paged content. Why should paged content be loaded through AJAX? Well, take the example of comments. You're viewing a page with lots of comments. You click a link to bring up the next 30 comments. You wait while the whole page refreshes.
Syndicate content