page.pre.php 1.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354
  1. <?php
  2. /**
  3. * @file template.preprocess-page.inc
  4. */
  5. /**
  6. * Override or insert variables into page templates.
  7. *
  8. * @param $vars
  9. * A sequential array of variables to pass to the theme template.
  10. * @param $hook
  11. * The name of the theme function being called.
  12. */
  13. # set variables for the logo and slogan (from Deco drupal 6.x theme)
  14. //$site_fields = array();
  15. //if ($vars['site_name']) {
  16. // $site_fields[] = check_plain($vars['site_name']);
  17. //}
  18. // if ($vars['site_slogan']) {
  19. // $site_fields[] = check_plain($vars['site_slogan']);
  20. // }
  21. $vars['site_title'] = '<h1><a href="/">'. $vars['site_name'] .'</a><span class="beta">beta</span></h1>'.'<span class="slogan">'.$vars['site_slogan'].'</span>';
  22. if (theme_get_setting('layout_enable_settings') == 'on')
  23. $vars['method'] = theme_get_setting('layout_method');
  24. $vars['primary_local_tasks'] = menu_primary_local_tasks();
  25. $vars['secondary_local_tasks'] = menu_secondary_local_tasks();
  26. $vars['title'] = false;
  27. $vars['breadcrumb'] = false;
  28. // global $language;
  29. // drupal_add_js(array('materiobasetheme' => array(
  30. // 'strings'=>array(
  31. // 'search'=>t('search'),
  32. // // 'filter'=>t('filter'),
  33. // 'site_name'=>t(variable_get('site_name', '')),
  34. // 'site_slogan'=>t(variable_get('site_slogan', '')),
  35. // ),
  36. // 'themePath'=> drupal_get_path('theme', 'materiobasetheme'),
  37. // 'language'=>$language->language,
  38. // )), 'setting');