Не получается поставить service_links. Точнее после добавления в template.php строк в тему zen:
switch($hook) {
case 'node':
if (module_exists('service_links')) {
$vars['service_links'] = theme('links', service_links_render($vars['node'], TRUE));
}
break;
}
return $vars;
}
Сайт не открывается.
не это ли мешает?
$vars['subtheme_directory'] = path_to_subtheme();
switch ($hook) {
case 'page':
// Add main Zen styles.
drupal_add_css($vars['directory'] .'/tabs.css', 'theme', 'all');
// Then add styles for this sub-theme.
drupal_add_css($vars['subtheme_directory'] .'/layout.css', 'theme', 'all');
drupal_add_css($vars['subtheme_directory'] .'/icons.css', 'theme', 'all');
drupal_add_css($vars['subtheme_directory'] .'/zen-classic.css', 'theme', 'all');
// Optionally add the fixed width CSS file.
if (theme_get_setting('zen_classic_fixed')) {
drupal_add_css($vars['subtheme_directory'] .'/zen-fixed.css', 'theme', 'all');
}
$vars['css'] = drupal_add_css();
$vars['styles'] = drupal_get_css();
// Avoid IE5 bug that always loads import print stylesheets
$vars['head'] = zen_add_print_css($vars['subtheme_directory'] .'/print.css');
if (module_exists('advanced_forum')) {
$vars = advanced_forum_addvars($hook, $vars);
}
}
return $vars;
Подскажите пожалуйста как заставить работать
Комментарии
<?php
function zen_variables($hook, $vars) {
$vars['subtheme_directory'] = path_to_subtheme();
switch ($hook) {
case 'page':
// Add main Zen styles.
drupal_add_css($vars['directory'] .'/tabs.css', 'theme', 'all');
// Then add styles for this sub-theme.
drupal_add_css($vars['subtheme_directory'] .'/layout.css', 'theme', 'all');
drupal_add_css($vars['subtheme_directory'] .'/icons.css', 'theme', 'all');
drupal_add_css($vars['subtheme_directory'] .'/zen-classic.css', 'theme', 'all');
// Optionally add the fixed width CSS file.
if (theme_get_setting('zen_classic_fixed')) {
drupal_add_css($vars['subtheme_directory'] .'/zen-fixed.css', 'theme', 'all');
}
$vars['css'] = drupal_add_css();
$vars['styles'] = drupal_get_css();
// Avoid IE5 bug that always loads import print stylesheets
$vars['head'] = zen_add_print_css($vars['subtheme_directory'] .'/print.css');
if (
module_exists('advanced_forum')) {$vars = advanced_forum_addvars($hook, $vars);
}
break;
case
'node':if (module_exists('service_links')) {
$vars['service_links'] = theme('links', service_links_render($vars['node'], TRUE));
}
break;
}
return $vars;
}
?>
Спасибо!