O'Reilly logo

Drupal 6 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

Changing the layout of a page using page.tpl.php

As we have seen in earlier chapters, the page template file, page.tpl.php, is responsible for the overall layout and markup of a Drupal page. Besides the basic HTML headers, various elements common to all pages in the site, such as the layout of regions, headers, footers, logos, slogans, breadcrumbs, and so on are, all positioned here.

In this recipe, we will look at modifying the page template file in order to move the search form—another element which is normally present across all pages—from the header to the footer.

Getting ready

It is possible that some themes will not have a page.tpl.php file of their own. This is usually because they are sub-themes and the template file will need to be imported ...

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