Hello. I was having trouble finding out exactly how to do this. On my site, I would like to have my blog use an entirely different layout than the rest of my site. I know to do this, you basically duplicate your page.tpl.php and make the necessary changes. The question I have is what must the name be for this file in order for my blog module to read from it, and not from the page.tpl.php? After naming it correctly, is there anything else I must do to have the blog read it? Any help is appreciated. Thanks!

Comments

nevets’s picture

You may not need a specific page.tpl.php, how do you want the blog pages different?

othermachines’s picture

Not sure if this is what you need but here's how to create template suggestions per node type/bundle:

In template.php:

function themename_preprocess_page(&$vars) { 
  if (isset($vars['node']->type)) { 
    $vars['theme_hook_suggestions'][] = 'page__' . $vars['node']->type; 
  } 
}

If your node type is named 'my_node_type', your template file would be named page--my-node-type.tpl.php. Be sure to clear your caches after making these changes.