function answers_theme_theme_registry_alter in Answers 7.4
Implements hook_theme_registry_alter().
See: http://www.metachunk.com/blog/adding-module-path-drupal-7-theme-registry.
File
- answers_theme/
answers_theme.module, line 14 - The Answers_Theme module.
Code
function answers_theme_theme_registry_alter(&$theme_registry) {
$mod_path = drupal_get_path('module', 'answers_theme');
// Munge on a copy.
$theme_registry_copy = $theme_registry;
_theme_process_registry($theme_registry_copy, 'phptemplate', 'theme_engine', 'pow', $mod_path);
$theme_registry += array_diff_key($theme_registry_copy, $theme_registry);
$hooks = array(
'node',
);
foreach ($hooks as $h) {
_answers_insert_after_first_element($theme_registry[$h]['theme paths'], $mod_path);
// Add in new function for textareas.
$theme_registry['form_element_label']['function'] = 'answers_theme_theme_form_element_label';
}
}