One of the nice things about theming in Drupal is the ease of overriding items when theming. For example, if you wanted to drastically alter the HTML of the pages for certain content types, you could do so with overrides like page-content_type.tpl.php. However, a lot of themes don’t have support for this out of the box including the popular Zen theme and sub-theme.
Here’s a code snippet from Drupal.org that does the job. I can’t take the credit for writing it; that belongs to Drupal member khonggiannet. Just paste this into the template.php in your theme and you’re ready to go.
Here’s the the code:
/**
*
* Override templates using page-[content-type-name].tpl.php
* From http://drupal.org/node/223440
*
*/
function themename_preprocess_page(&$variables) {
if ($variables['node']->type != "") {
$variables['template_files'][] = "page-" . $variables['node']->type;
}
}