Skip to content

Instantly share code, notes, and snippets.

View paolomainardi's full-sized avatar

Paolo Mainardi paolomainardi

View GitHub Profile
function d_geo_theme($existing) {
return array(
'views_views_json_style_simple__layer_explorer_library__page_2' => array (
'arguments' => array('view' => NULL, 'options' => NULL, 'rows' => NULL, 'title' => NULL),
'template' => 'views-views-json-style-simple--layer-explorer-library--page-2',
'original hook' => 'views_views_json_style',
'path' => drupal_get_path('module', 'drupal_geoext') . '/theme',
'preprocess functions' => array(
'template_preprocess',
/**
* Implementation of HOOK_theme().
*/
function ildn_base_theme(&$existing, $type, $theme, $path) {
$hooks = zen_theme($existing, $type, $theme, $path);
/* Override theme path for block templates */
$existing['block']['theme paths'][] = drupal_get_path('theme', 'ildn_base').'/templates/block';
return $hooks;
}
function ildn_base_preprocess_block(&$vars, $hook) {
foreach ($vars['template_files'] as $template_file) {
$vars['template_files'][] = 'block/'.$template_file;
}
}