Advertisement
Guest User

Untitled

a guest
Jul 27th, 2017
49
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
PHP 0.71 KB | None | 0 0
  1. <?php
  2. //template.php
  3.  
  4. function BPSTARTER_preprocess_page(&$vars, $hook) {
  5.   global $theme_path;
  6.  
  7.   $vars['theme_path'] = $theme_path  ;
  8.   $vars['main_menu'] = menu_main_menu();
  9.   $vars['search_form'] = render(drupal_get_form('search_box'));
  10. }
  11.  
  12. /**
  13.  * Implementation of HOOK_theme().
  14.  */
  15. function BPSTARTER_theme(&$existing, $type, $theme, $path) {
  16.  
  17.   $hooks = blueprint_theme($existing, $type, $theme, $path);
  18.   // Add your theme hooks like this:
  19.   /*
  20.   $hooks['hook_name_here'] = array( // Details go here );
  21.   */
  22.   // @TODO: Needs detailed comments. Patches welcome!
  23.  
  24.   $hooks['search_box'] = array(
  25.     'render element' => 'form',
  26.     'template' => 'templates/search-form');
  27.  
  28.   return $hooks;
  29. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement