From 447d6a628bde3891a4be70a3d9131023214d00f3 Mon Sep 17 00:00:00 2001 From: webchick Date: Tue, 28 Feb 2012 10:22:59 -0800 Subject: Issue #1430300 by mradcliffe, xjm, effulgentsia, NROTC_Webmaster: Fixed Preprocess functions in an include file fail to get called when the theme implements a suggestion override. --- includes/theme.inc | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'includes/theme.inc') diff --git a/includes/theme.inc b/includes/theme.inc index da4200e56..0712f8797 100644 --- a/includes/theme.inc +++ b/includes/theme.inc @@ -991,6 +991,13 @@ function theme($hook, $variables = array()) { if (isset($info['base hook'])) { $base_hook = $info['base hook']; $base_hook_info = $hooks[$base_hook]; + // Include files required by the base hook, since its variable processors + // might reside there. + if (!empty($base_hook_info['includes'])) { + foreach ($base_hook_info['includes'] as $include_file) { + include_once DRUPAL_ROOT . '/' . $include_file; + } + } if (isset($base_hook_info['preprocess functions']) || isset($base_hook_info['process functions'])) { $variables['theme_hook_suggestion'] = $hook; $hook = $base_hook; -- cgit v1.2.3