March 2011

Mar 29, 2011

Being a coder certainly has it's benefits. But without critical theming skills, you can start to feel a little like a sandwich without tomatoes. Or a crossbow without arrows. Or a pair of pink sunglasses without sequins glued on them. Or a ... well, you probably get the picture. But, if you do get the picture, can you theme it?

We're moving steadily forth into our 5th week of theming videos, and things are starting to get interesting. After laying down the basics like knowing what the theme layer is for and how to find the source of any output in Drupal, we're starting to peek into some theme folders and see what treasures lie within. Theme directories are a wildcard, you have a lot of freedom to set things up in a multitude of ways. But that freedom comes at the price of sometimes not knowing where to start.

This week is dedicated to theme file-gazing. We first look through the core Drupal themes and see how they have their files set up, and then we move onto four of the most popular contributed themes: Zen, Basic (a Zen offshoot), Fusion (FREE video) and Marinelli. Each theme has unique strategies and lessons to teach, and will help you get a feel for where to start as you develop your theme or modify an existing theme.

Next week we'll be getting deep into code, leveraging all of the tools and techniques we've reviewed this last month and begin to build an entire theme from scratch.

Resource pack has been updated

Several issues have been fixed in the source code resource pack, so please download the new version if you're following along.

Thanks, and enjoy!
Chris Shattuck

Mar 22, 2011

Themes are touchy beasts. A line of funked-out CSS or a misnamed template file can send you careening down a path of sadistic uncertainty if you don't know what you're looking for. Well, here at Build a Module.com we think that's a little unfair. We should be able to change how our sites look without fear of wasting an entire day barking up the wrong tree, and this next batch of new videos is all about absolutely crushing that fear.

To begin with, we dive into some theme troubleshooting, looking at what happens when some HTML output you're trying to modify is getting lost in the shuffle. Next, we help you troubleshoot CSS issues, where styles you're trying to add just don't seem to be working. Since these last two videos are part the first chapter in our Drupal Theming Essentials series, we wrap it up with a review of the rich theming topics we've covered and some suggestions for next steps.

But wait, that's not all! We also begin our next chapter - aptly titled How to Build and Modify a Drupal Theme or Sub-Theme - with an overview of the themes that come with Drupal, along with a couple other core theme resources and a guide on where to put new themes. We then take you on a tour of the different components of a theme, including the .info file, the template.php file and lots more.

Next week we'll be diving into how to structure a theme directory and take a look at several interesting examples in both core Drupal and contributed themes.

Spread the code "springbreak2011" for FREE form-building videos!

Spring break is a time where people work on their form, right? Sun bathing, surfing, lounging about. As a conciliatory prize for those of you returning from spring break, or suffering in some other way from the end of those blissful days, we are offering all of the videos on our site that have the word "form" in them for free this next week. But only if you know the code.

If you know anyone that could benefit from a little Form API action, send a little tweet gently encouraging them to go to https://buildamodule.com/code and enter the code springbreak2011. That will grant them free access to form-building videos until March 28th, no strings attached!

Thanks and enjoy!
Chris Shattuck

Mar 15, 2011

This year's Drupalcon was most excellent! I had the opportunity to meet a number of current and soon-to-be subscribers, and get some feedback on what you'd like to see in the future. Overall it seems like we're headed in the right direction, and I wanted to thank you so much for all your great ideas and insights. I'm looking forward to more face time at the next Drupal event!

As we complete the first chapter in the "Drupal Theming Essentials" video series, we demonstrate how to work with view modes in the Drupal user interface, how to leverage field formatters to re-use themable output on the field level, and discuss various standards around working with the theme layer. If any of that sounds a little foreign to you, don't worry, these videos will gently introduce you to each concept.

How to adjust node view modes through the user interface
Last week we talked about what view modes are, and in this video we take it a little further to explore what can be done with view modes in the Drupal user interface. (subscriber-only)

What field formatters are and how to use them to modify field output
Field formatters are a great way to modify the output of a field in a reusable way. In this video we look over the existing user interface for working with field formatters to get a feel for what they are and how you might use them in practice. (subscriber-only)

How coding standards apply to the theme layer, and how to add comments to template files
Coding standards are critical for working with other team members on a project, and in this video we look at how standards apply to the theme layer, as well as some best practices in writing comments for template files. (FREE today only!)

Template file coding standards and conventions
Template files are one of the most important interfaces between designers and developers. Here we delve into how to write template files in such a way as to make it as easy as possible for themers to make changes without having to dig into heavy development work. (FREE today only!)

How to apply CSS coding standards
The CSS standards are currently in draft status, but they can give you some tips on best practices when working with CSS, splitting CSS into multiple files, and structuring your CSS definitions. (subscriber-only)

Mar 8, 2011

Last week we rolled out a nice little interface upgrade which is subtle enough that I thought it might be good to point it out with huge red arrows. With the new navigation tools, you no longer have to scroll through the (rather large) list of videos to get to the one you're looking for. Instead, just use the arrows to move forward or back, or click the list icon to display a pop-over will all the videos in the current series you're viewing, plus navigation to switch series' as well. If you're spending a lot of time on Build a Module.com, then you should notice a pleasant productivity boost.

Interface improvement with big red arrows

The new Drupal theming videos

This week we release our second batch of "Drupal Theming Essentials" videos. In this one, we tackle a couple of hairy questions about where to put the code you use to override output, discuss a couple of essential theming tools, and discuss view modes - a handy way to modify node output code-free. Enjoy!

How to decide whether to use a module or a theme for your modifications
When using a theme function to override output, is it better to put your code in a module, or in the template.php file? In this video we give you a solid answer to this sticky question. (subscriber-only)

How to decide when to use a theme function or template file
Theming functions and template files are both legitimate places to put your output-related logic, and it can be a little painful trying to figure out which one is right for what situation. In this video we provide some clear benefits to each method and match up situations to solutions. (subscriber-only)

How the theme registry works
If you don't understand what the theme registry is or how it works, you will likely find yourself banging your head against a brick wall at some point. Save yourself a metal plate in your skull and watch this succint explaination. (subscriber-only)

How to find out where any piece of output comes from
Finding out which template files or theme functions or preprocessing functions or processing functions are responsible for what kind of output where is super tricky without the Theme Developer module. In this video we dig into this module and show you how to find the origin for virtually any output in Drupal. (FREE)

What view modes are and why you would use them
View modes, previously known as "build modes" in Drupal 6, provide a rich method of consistantly displaying node content in various contexts. Plus, it wraps it all in a nice user interface for site builder types. In this video we discuss the concept of a view mode and how you'd be likely to use them. (subscriber-only)

Mar 1, 2011

We're opening up the entire online video library (over 24 hours of video) for free on March 11th for the Drupalcon sprint day. If you plan on participating in any of the sprints, this is a great opportunity to have a quick visual reference library at your fingertips. If you won't be at Drupalcon, you still have full access and can use the day to build some new skills.

First videos in the Drupal Theming Essentials series

This week we released the first 5 videos in the new Drupal Theming Essentials series. In this series, we're going to give you all the tools that you need to modify the output of virtually anything in Drupal, from blocks to nodes to links. More importantly, we'll help you answer some common questions like "Where do I put this modification?" or "Do I use a module or a theme for this" or "How to I hide that pesky RSS icon".

Here are some additional topics that we'll be covering over the next several weeks:

  • How to build a theme from scratch
  • The right way to modify or extend a theme
  • How to use sub-themes
  • Using template files and theming functions
  • Conceptual groundwork to get a better idea of where coding and designing end and where theming starts.
  • Lots, lots more!

And below is the list of new videos, in which we cover issues around the ambiguous nature of theming:

Who these theming videos are for and what they do (and don't) cover
In this video, we explain what these theming videos are doing on a site geared towards module building, and what we purposefully exclude in order to focus on the most common and important concepts and techniques. (FREE)

What is the difference between designing, theming and coding, and why do they overlap so much?
This video answers the question of why it is so difficult to draw a line between these different roles, and why do these roles exist in the first place. (FREE)

What are all of the different ways to modify Drupal output?
If you've ever found your head spinning as you attempt to figure out how to modify some output, it might be because there are so many possible approaches. In this video, we discuss different approaches including using CSS, installing contributed modules, and using alter functions within a module. (subscriber-only)

How to determine which method to use when modifying output
Once you're aware of the different approaches for modifying output, this video will help you answer the question of which method to chose for various situations. (subscriber-only)

A conceptual introduction to the Features module for exporting configuration options as code
In general, making output modifications with configuration changes is difficult to maintain and copy from one site to another. However, the Features module offers one solution for this, which may influence whether you take a modular or configuration-based approach to your modifications. (subscriber-only)