O'Reilly logo

Drupal 7 Theming Cookbook by Karthik Kumar

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Finding the right function to use to theme an object

In the previous chapter, we saw how to find out which theme function is being used to theme an element the username in a page and subsequently, learned to override it. However, while writing modules or when we are looking at ways to render data loaded from the database, it is also not uncommon to be at a loss to know which function to use to theme a Drupal object.

In this recipe, we will look to source potential solutions which can be used to render a typical Drupal user object. We will be accomplishing this task using the Devel module and available documentation.

Getting ready

The Devel module which can be downloaded from http://drupal.org/project/devel is assumed to be installed and enabled. ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required