Listing all available variables in a template file
Until we become familiar with a template, it can be quite daunting to understand what is going on as all that we see is a host of variables which are being positioned using markup. Frequently, it is important to know which variables are available to us in the file and to also understand what they contain.
In this recipe, we will look at how to list all the variables available inside the page.tpl.php
template file using the Theme developer module.
Getting ready
The Devel and Theme developer modules need to be installed and enabled as per the previous recipe. The Development block is assumed to have been enabled.
How to do it...
The variables inside the page.tpl.php
template can be listed by following these steps:
Click on the Enable Theme developer link in the Development block.
Check the Themer info checkbox.
Click on any part of the page. This should load theme-related information inside the Drupal Themer Information pop-up.
In the pop-up, if the...