In my theme, I have page.tpl.php and page--node--1.tpl.php.
When page--node--1.tpl.php is rendered, everything in page.tpl.php is lost. I only want page--code--1.tpl.php to replace the $content line in page.tpl.php and inherit everything else in page.tpl.php.
How can I do this? Do I need to first create a template for the content type?
Below is what I have in my template.php
if (strtolower($vars['template_files'][0]) == "page-search") {
$vars["template_files"] = array();
$vars["template_files"][] = 'page-search';
} else {
if ($vars["template_files"][2] != 'page-node-edit') {
if (isset($vars['node']) && ($vars['node']->type == "mytheme_page" || $vars['node']->type == "person" || $vars['node']->type == "blank_page")) {
if ($vars["template_files"][2] == "page-front") {
$vars["template_files"] = array();
$vars["template_files"][] = 'page-home-mytheme';
} else {
$vars["template_files"] = array();
if ($vars['node']->type == "blank_page") {
$vars["template_files"][] = 'page-blank';
} else {
//print "made it here";exit;
$vars["template_files"][] = 'page-mytheme';
}
}
} elseif ($alias == "sitemap") {
$vars["template_files"] = array();
$vars["template_files"][] = 'page-blank';
}
}
}