Skip to main content

Drupal Documentation

How to theme the User Login page in Maintenance Mode

A recent client wanted to remove everything from the user login page when the site was in maintenance (or Site off-line as its referred to in most system messages and documentation). Just showing the user login form when the site is off-line actually makes a lot of sense because whats the point of showing things like primary links, search block or whatever else might show on your normal user login page.

Using CSS clip as an Accessible Method of Hiding Content

Its relatively easy to hide content in Drupal using CSS, however its a whole different ball game to hide content and keep it accessible to all site visitors. Disabled web users may be using a screen reader or other Assistive Technology. For Drupal 7 we wanted a way to hide content that worked in all browsers and avoided many of the issues associated with current techniques.

The idea was to develop a new CSS class that could be applied to any element we needed to hide. We called this class .element-invisible and set about testing properties and values to make this work, in all browsers and all AT devices. First lets look at some of the current techniques we looked into and tested for Drupal 7, then I’ll introduce a new technique I came up using the little known clip property and see how it stacks up - I think you’ll be intrigued.

100 Percent width Header and Footer Backgrounds in Adaptivetheme

I’ve been asked a few times by Drupal themers and designers how to do 100% header and footer backgrounds in Adaptivetheme—and retain the theme settings so end users can still adjust the overall page width. Actually this is pretty easy - its just a matter of adding a couple of wrapper DIV’s in the right places and overriding the layout variables that Adaptivetheme uses to set the width.

Export Adaptivethemes Advanced Theme Settings

In the latest bleeding edge DEV version of Adaptivetheme we’ve introduced a new feature—the ability to export your theme settings. This is useful if you need to move your Drupal theme and you can’t just export and move the database as well.

Add Superfish Drop Menus to Any Theme, Easily

How to add a Superfish drop menu to Genesis or Adaptivetheme is one of the most common questions I get. Believe when I say I get emails from well intentioned Drupal users on a weekly basis asking me this. So now, please stop emailing me, I relent, heres how its done.

Rounded Corner Tools and Techniques

Heres a quick list of rounded corner tools and techniques you can use in your Drupal theme.

Font Family Groups

Quick list of some handy font family groups (often called “font stacks”) for web design and Drupal theme development. Includes the three groups that come with Adaptivetheme starter theme and an example of how to set the font-family in your CSS.

How to Add unique classes to Drupal menus

Sometimes you want to be able to style menu items individually. For example you may want to use image replacement to display icons instead of the text, or you may want to make one menu item stand out from the rest.

Drupals Primary and Secondary links allow you to do this because they print a class on the li that includes the mlid, so its easy to target a particular link doing something like:

li.menu-123 a {font-weight: bold;}

But, in normal Drupal menus, the ones that appear in blocks, no such classes appear, which leaves them all with the same style.

How to add a sidebar-top region in Genesis

Screen shot showing sidebar top region

Genesis supports 3 different layouts including both sidebars on either the left or right of the main content. In this configuration it can be useful to have a sidebar-top region that spans the width of both sidebars, but sits on top of them.

An example of when you might want to do this would be to display a fixed height banner or contextual ads. Its not good for content that will change in height as it could then overflow the div—while the fixed height limitation could be overcome, this tutorial is meant for beginners and is a simple strait forward explanation of how to add new regions in Drupal and how to position the new sidebar-top region using CSS.

This tutorial shows you how to do this in the Genesis starter theme for Drupal 6.

How to Write A Drupal Design Brief

PSD icon with Drupal icon

A design brief, sometimes know as the creative brief is a relatively short, high-level document that clearly outlines the important elements of the web design project—whether its a full Drupal theme development project or an ROS banner campaign each project needs this foundation document.