As the get_template_dir() function defined in:
/includes/classes/template_func.php
is used to figure out which which files override which, I modified this to output (to the screen) the paths of the files which it decides to include, immediately before the file is returned.
Note: the first commented-out debugging statement comes stock with 1.3.7 and is useless in this regard as it only outputs the inputs of the function, and not the location of the files post-override-rules.
This saved my sanity and hopefully will save a whole slew of you a ton of time, frustration, and questions:
1) edit /includes/classes/template_func.php
2) modify the get_template_dir function to resemble the following:
PHP Code:
function get_template_dir($template_code, $current_template, $current_page, $template_dir, $debug=false) {
// echo 'template_default/' . $template_dir . '=' . $template_code;
$sanitydebug=true;
if ($this->file_exists($current_template . $current_page, $template_code)) {
if($sanitydebug==true){ echo $current_template . $current_page . '/' . $template_code . '<br />'; }
return $current_template . $current_page . '/';
} elseif ($this->file_exists(DIR_WS_TEMPLATES . 'template_default/' . $current_page, ereg_replace('/', '', $template_code), $debug)) {
if($sanitydebug==true){ echo DIR_WS_TEMPLATES . 'template_default/' . $current_page . '/' . $template_code . '<br />'; }
return DIR_WS_TEMPLATES . 'template_default/' . $current_page;
} elseif ($this->file_exists($current_template . $template_dir, ereg_replace('/', '', $template_code), $debug)) {
if($sanitydebug==true){ echo $current_template . $template_dir . '/' . $template_code . '<br />'; }
return $current_template . $template_dir;
} else {
if($sanitydebug==true){ echo DIR_WS_TEMPLATES . 'template_default/' . $template_dir . '/' . $template_code . '<br />'; }
return DIR_WS_TEMPLATES . 'template_default/' . $template_dir;
// return $current_template . $template_dir;
}
}
3) To disable these include messages from being displayed, simply change the $sanitydebug line to say:
PHP Code:
$sanitydebug=false;