/** * Override or insert PHPTemplate variables into the templates. */ function boldy_preprocess_page(&$vars) { $vars['tabs2'] = menu_secondary_local_tasks(); // Hook into color.module if (module_exists('color')) { _color_page_alter($vars); } // Classes for body element. Allows advanced theming based on context // (home page, node of certain type, etc.) $classes = explode(' ', $vars['body_classes']); // Remove the mostly useless page-ARG0 class. if ($index = array_search(preg_replace('![^abcdefghijklmnopqrstuvwxyz0-9-_]+!s', '', 'page-' . drupal_strtolower(arg(0))), $classes)) { unset($classes[$index]); } if (!$vars['is_front']) { // Add unique class for each page. $path = drupal_get_path_alias($_GET['q']); $classes[] = boldy_id_safe('page-' . $path); // Add unique class for each website section. list($section, ) = explode('/', $path, 2); if (arg(0) == 'node') { if (arg(1) == 'add') { $section = 'node-add'; } elseif (is_numeric(arg(1)) && (arg(2) == 'edit' || arg(2) == 'delete')) { $section = 'node-' . arg(2); } } $classes[] = boldy_id_safe('section-' . $section); } $vars['body_classes_array'] = $classes; $vars['body_classes'] = implode(' ', $classes); // Concatenate with spaces. }
function phptemplate_preprocess_page(&$vars) { $vars['tabs2'] = menu_secondary_local_tasks(); if (module_exists('path')) { $alias = drupal_get_path_alias(str_replace('/edit', '', $_GET['q'])); if ($alias != $_GET['q']) { $suggestions = array(); $template_filename = 'page'; foreach (explode('/', $alias) as $path_part) { $template_filename = $template_filename . '-' . $path_part; $suggestions[] = $template_filename; } $vars['template_files'] = array_merge((array) $suggestions, $vars['template_files']); } } //todo i think this can be deleted if (arg(0) == 'taxonomy' && arg(1) == 'term' && is_numeric(arg(2))) { $termid = arg(2); $parent_term = taxonomy_get_parents($termid); if (key($parent_term) == EMAILS_TERM_ID) { $term = taxonomy_get_term($termid); $vars['template_file'] = 'page-taxonomy-term-emails'; } } }
/** * Override or insert variables into the page template. */ function seven_preprocess_page(&$vars) { $vars['primary_local_tasks'] = menu_primary_local_tasks(); $vars['secondary_local_tasks'] = menu_secondary_local_tasks(); $vars['ie_styles'] = '<!--[if lt IE 7]><style type="text/css" media="screen">@import ' . path_to_theme() . '/ie6.css";</style><![endif]-->'; $vars['back_to_site'] = l(t('Back to the front page'), ''); }
/** * Preprocessor for theme('page'). */ function cube_preprocess_page(&$vars) { // Automatically adjust layout for page with right sidebar content if no // explicit layout has been set. $layout = module_exists('context_layouts') ? context_layouts_get_active_layout() : NULL; if (arg(0) != 'admin' && !empty($vars['page']['right']) && (!$layout || $layout['layout'] == 'default')) { $vars['theme_hook_suggestion'] = 'page__context_layouts_cube_columns'; drupal_add_css(drupal_get_path('theme', 'cube') . '/layout-sidebar.css'); } // Clear out help text if empty. if (empty($vars['help']) || !strip_tags($vars['help'])) { $vars['help'] = ''; } // Help text toggler link. $vars['help_toggler'] = l(t('Help'), $_GET['q'], array('attributes' => array('id' => 'help-toggler', 'class' => array('toggler')), 'fragment' => 'help-text')); // Overlay is enabled. $vars['overlay'] = module_exists('overlay') && overlay_get_mode() === 'child'; if ($vars['overlay']) { } // Display user links $vars['user_links'] = _cube_user_links(); // Display tabs $vars['primary_tabs'] = menu_primary_local_tasks(); $vars['secondary_tabs'] = menu_secondary_local_tasks(); }
/** * Override or insert variables into the page template. */ function garland_preprocess_page(&$vars) { $vars['tabs2'] = menu_secondary_local_tasks(); if (isset($vars['main_menu'])) { $vars['primary_nav'] = theme('links__system_main_menu', array('links' => $vars['main_menu'], 'attributes' => array('class' => array('links', 'main-menu')), 'heading' => array('text' => t('Main menu'), 'level' => 'h2', 'class' => array('element-invisible')))); } else { $vars['primary_nav'] = FALSE; } if (isset($vars['secondary_menu'])) { $vars['secondary_nav'] = theme('links__system_secondary_menu', array('links' => $vars['secondary_menu'], 'attributes' => array('class' => array('links', 'secondary-menu')), 'heading' => array('text' => t('Secondary menu'), 'level' => 'h2', 'class' => array('element-invisible')))); } else { $vars['secondary_nav'] = FALSE; } // Prepare header. $site_fields = array(); if (!empty($vars['site_name'])) { $site_fields[] = check_plain($vars['site_name']); } if (!empty($vars['site_slogan'])) { $site_fields[] = check_plain($vars['site_slogan']); } $vars['site_title'] = implode(' ', $site_fields); if (!empty($site_fields)) { $site_fields[0] = '<span>' . $site_fields[0] . '</span>'; } $vars['site_html'] = implode(' ', $site_fields); // Set a variable for the site name title and logo alt attributes text. $slogan_text = filter_xss_admin(variable_get('site_slogan', '')); $site_name_text = filter_xss_admin(variable_get('site_name', 'Drupal')); $vars['site_name_and_slogan'] = $site_name_text . ' ' . $slogan_text; }
/** * Override or insert variables into the page template. */ function garland_preprocess_page(&$vars) { $vars['tabs2'] = menu_secondary_local_tasks(); if (isset($vars['main_menu'])) { $vars['primary_nav'] = theme('links', array('links' => $vars['main_menu'], 'attributes' => array('class' => array('links', 'main-menu')), 'heading' => array('text' => t('Main menu'), 'level' => 'h2', 'class' => array('element-invisible')))); } else { $vars['primary_nav'] = FALSE; } if (isset($vars['secondary_menu'])) { $vars['secondary_nav'] = theme('links', array('links' => $vars['secondary_menu'], 'attributes' => array('class' => array('links', 'secondary-menu')), 'heading' => array('text' => t('Secondary menu'), 'level' => 'h2', 'class' => array('element-invisible')))); } else { $vars['secondary_nav'] = FALSE; } // Prepare header $site_fields = array(); if (!empty($vars['site_name'])) { $site_fields[] = check_plain($vars['site_name']); } if (!empty($vars['site_slogan'])) { $site_fields[] = check_plain($vars['site_slogan']); } $vars['site_title'] = implode(' ', $site_fields); if (!empty($site_fields)) { $site_fields[0] = '<span>' . $site_fields[0] . '</span>'; } $vars['site_html'] = implode(' ', $site_fields); }
/** * Override or insert variables into the page template. */ function garland_preprocess_page(&$vars) { $vars['tabs2'] = menu_secondary_local_tasks(); if (isset($vars['main_menu'])) { $vars['primary_nav'] = theme('links', $vars['main_menu'], array('class' => array('links', 'main-menu')), array('text' => t('Main menu'), 'level' => 'h2', 'class' => array('element-invisible'))); } else { $vars['primary_nav'] = FALSE; } if (isset($vars['secondary_menu'])) { $vars['secondary_nav'] = theme('links', $vars['secondary_menu'], array('class' => array('links', 'secondary-menu')), array('text' => t('Secondary menu'), 'level' => 'h2', 'class' => array('element-invisible'))); } else { $vars['secondary_nav'] = FALSE; } $vars['ie_styles'] = garland_get_ie_styles(); // Prepare header $site_fields = array(); if (!empty($vars['site_name'])) { $site_fields[] = check_plain($vars['site_name']); } if (!empty($vars['site_slogan'])) { $site_fields[] = check_plain($vars['site_slogan']); } $vars['site_title'] = implode(' ', $site_fields); if (!empty($site_fields)) { $site_fields[0] = '<span>' . $site_fields[0] . '</span>'; } $vars['site_html'] = implode(' ', $site_fields); // Hook into color.module if (module_exists('color')) { _color_page_alter($vars); } }
/** * Override or insert PHPTemplate variables into the templates. */ function phptemplate_preprocess_page(&$vars) { $vars['tabs2'] = menu_secondary_local_tasks(); // Hook into color.module if (module_exists('color')) { _color_page_alter($vars); } // handy helper for themes, not related to 404 issue $vars['base_path'] = base_path(); // Only does the check if required if (!$vars['show_blocks']) { global $theme; $regions = system_region_list($theme); foreach (array_keys($regions) as $region) { // Only set left and right regions // Drupal core sets the other blocks already // IMHO this shows a real lack of design considerations for leaving these out! if ($region == 'left' || $region == 'right') { $blocks = theme('blocks', $region); if (isset($variables[$region])) { $vars[$region] .= $blocks; } else { $vars[$region] = $blocks; } } } } }
/** * Override or insert PHPTemplate variables into the templates. */ function phptemplate_preprocess_page(&$vars) { $vars['tabs2'] = menu_secondary_local_tasks(); // Hook into color.module if (module_exists('color')) { _color_page_alter($vars); } }
/** * Implementation of preprocess_page(). */ function tao_preprocess_page(&$vars) { // Split primary and secondary local tasks $vars['primary_local_tasks'] = menu_primary_local_tasks(); $vars['secondary_local_tasks'] = menu_secondary_local_tasks(); // Link site name to frontpage $vars['site_name'] = l($vars['site_name'], '<front>'); }
/** * Implements hook_preprocess_page(). */ function vdb_preprocess_page(&$vars) { $menu1 = menu_navigation_links('main-menu', 0); $vars['menu_first'] = theme('links__system_main_menu', array('links' => $menu1, 'attributes' => array('id' => 'main-menu-links'))); $menu2 = menu_navigation_links('main-menu', 1); $vars['menu_second'] = empty($menu2) ? '' : theme('links__system_main_menu', array('links' => $menu2, 'preserve_query' => TRUE, 'attributes' => array('class' => array('tabs', 'primary')))); $vars['tabs_first'] = menu_primary_local_tasks(); $vars['tabs_second'] = menu_secondary_local_tasks(); }
/** * Override or insert PHPTemplate variables into the templates. */ function phptemplate_preprocess_page(&$vars) { $view = get_artx_drupal_view(); $message = $view->get_incorrect_version_message(); if (!empty($message)) { drupal_set_message($message, 'error'); } $vars['tabs'] = menu_primary_local_tasks(); $vars['tabs2'] = menu_secondary_local_tasks(); }
/** * Implements template_preprocess_html(). * * The changes made in this function affect the variables for the html.tpl.php * template file, which is located in templates/html.tpl.php of this theme. * Using drupal_css_css() is covered on pages 344-345. */ function dgd7_preprocess_html(&$vars) { // Unfortunately, the XHTML+RDFa 1.0 doctype is hardcoded. We don't want an // XHMTL doctype and the RDFa version is old. The following code changes it // to HTML+RDFa 1.1 when the RDF module is enabled, and a plain jane HTML5 // doctype when it's not. To learn more about theming with RDFa in Drupal 7 // see http://lin-clark.com/blog/theming-html5-and-rdfa-drupal-7 if (module_exists('rdf')) { $vars['doctype'] = '<!DOCTYPE html PUBLIC "-//W3C//DTD HTML+RDFa 1.1//EN">' . "\n"; $vars['rdf_profile'] = ' profile="' . $vars['grddl_profile'] . '"'; } else { $vars['doctype'] = '<!DOCTYPE html>' . "\n"; $vars['rdf_profile'] = ''; } // Add externally hosted files. This will not work if entered in .info file. // Setting the group to CSS_THEME will load these files in the "theme group" // which load after system and module CSS files. This is not terribly // important in this case, but we do need to specify "external" as TRUE. // Ideally that wouldn't be necessary it would "just work" like // drupal_add_js(). See http://drupal.org/node/953340 to help make it happen. drupal_add_css('http://fonts.googleapis.com/css?family=Droid+Serif:regular,italic,bold,bolditalic&subset=latin', array('external' => TRUE, 'group' => CSS_THEME)); drupal_add_css('http://fonts.googleapis.com/css?family=Droid+Sans:regular,bold&subset=latin', array('external' => TRUE, 'group' => CSS_THEME)); // Create a variable containing the path to the theme. We'll use this in // in html.tpl.php. $vars['path'] = drupal_get_path('theme', 'dgd7'); // Add the regular theme stylesheets. // This is done here as opposed to using the .info file so that we can control // the order. Since we cannot add the external CSS files via .info and we need // those to load first, we add them all here. drupal_add_css($vars['path'] . '/css/layout.css', array('group' => CSS_THEME)); drupal_add_css($vars['path'] . '/css/forms.css', array('group' => CSS_THEME)); drupal_add_css($vars['path'] . '/css/style.css', array('group' => CSS_THEME)); // We have a separate CSS file for styling the tabs that we only want to load // when there are actually tabs present. The following code checks for the // existence of primary and secondary tabs and then proceeds to load the CSS // file if needed. if (menu_primary_local_tasks() || menu_secondary_local_tasks()) { drupal_add_css($vars['path'] . '/css/tabs.css', array('group' => CSS_THEME, 'preprocess' => FALSE)); } // Add a print stylesheet. drupal_add_css($vars['path'] . '/css/print.css', array('group' => CSS_THEME, 'media' => 'print', 'preprocess' => FALSE)); // Add a conditional stylesheet for Internet Explorer. // The "browsers" key allows you to specify what versions of IE to target. In // this case we are targeting "less than or equal to IE 7". Drupal will wrap // the code for this stylesheet in conditional comments: // "<!--[if lte IE 7]> … <![endif]-->. For more details about conditional // comments see: http://www.quirksmode.org/css/condcom.html drupal_add_css($vars['path'] . '/css/ie.css', array('browsers' => array('IE' => 'lte IE 7', '!IE' => FALSE), 'group' => CSS_THEME, 'preprocess' => FALSE)); // In template_preprocess_html() we have easy access to the "class" attribute // for the <body> element. Here we add a helper class that indicates that // there is no title for the page to help styling the content region easily. if (!drupal_get_title()) { $vars['classes_array'][] = 'no-title'; } }
/** * Adds clearfix to tabs. */ function scholar_base_menu_local_tasks() { $output = ''; if (menu_primary_local_tasks()) { $output .= '<ul class="tabs primary clearfix">' . menu_primary_local_tasks() . '</ul>'; } if (menu_secondary_local_tasks()) { $output .= '<ul class="tabs secondary clearfix">' . menu_secondary_local_tasks() . '</ul>'; } return $output; }
function earthen_menu_local_tasks() { $output = ''; if ($primary = menu_primary_local_tasks()) { $output .= $primary; } if ($secondary = menu_secondary_local_tasks()) { $output .= $secondary; } return $output; }
/** * Duplicate of theme_menu_local_tasks() but adds clear-block to tabs. */ function phptemplate_menu_local_tasks() { $output = ''; if ($primary = menu_primary_local_tasks()) { $output .= '<ul class="tabs primary clear-block">' . $primary . '</ul>'; } if ($secondary = menu_secondary_local_tasks()) { $output .= '<ul class="tabs secondary clear-block">' . $secondary . '</ul>'; } return $output; }
/** * Override or insert variables into the page template. */ function seven_preprocess_page(&$vars) { $vars['primary_local_tasks'] = menu_primary_local_tasks(); $vars['secondary_local_tasks'] = menu_secondary_local_tasks(); // get all the current css information into an array $css = drupal_add_css(); // Removing the css files of vertical tabs module because and use the seven style instead. unset($css['all']['module'][drupal_get_path('module', 'vertical_tabs') . '/vertical_tabs.css']); // now place the remaining css files back into the template variable for rendering $vars['styles'] = drupal_get_css($css); }
/** * Override or insert PHPTemplate variables into the templates. */ function cp_theme_preprocess_page(&$vars, $hook) { $tabs2 = menu_secondary_local_tasks(); if ($tabs2) { $vars['tabs2'] = '<ul class="tabs secondary clear-block">' . menu_secondary_local_tasks() . '</ul>'; } //adds cp page classes $body_classes = array($vars['body_classes']); list($section, ) = explode('/', $_GET['q'], 1); $body_classes[] = scholar_base_id_safe('page-' . $section); $vars['body_classes'] = implode(' ', $body_classes); }
/** * Implements theme_preprocess_page(). */ function townsquare_bootstrap_preprocess_page(&$vars) { global $user; $vars['primary_local_tasks'] = menu_primary_local_tasks(); $vars['secondary_local_tasks'] = menu_secondary_local_tasks(); // The following menu stuff is lame foreach ($vars['main_menu'] as $item => $options) { $vars['main_menu'][$item]['html'] = TRUE; $vars['main_menu'][$item]['attributes']['id'] = 'menu-link-' . drupal_clean_css_identifier($options['href']); } $admin_menu = menu_tree_all_data('management'); $children = array_pop($admin_menu); if ($children) { foreach ($children['below'] as $key => $value) { $children['below'][$key]['below'] = array(); } $vars['admin_menu'] = menu_tree_output($children['below']); } // Add user picture if logged in if ($user->uid) { $vars['user_name'] = check_plain($user->name); if (!empty($user->picture)) { if (is_numeric($user->picture)) { $user->picture = file_load($user->picture); } if (!empty($user->picture->uri)) { $filepath = $user->picture->uri; } } elseif (variable_get('user_picture_default', '')) { $filepath = variable_get('user_picture_default', ''); } if (isset($filepath)) { $alt = t("@user's picture", array('@user' => format_username($user))); if (module_exists('image') && file_valid_uri($filepath) && ($style = variable_get('user_picture_style', ''))) { $vars['user_picture'] = theme('image_style', array('style_name' => $style, 'path' => $filepath, 'alt' => $alt, 'title' => $alt)); } else { $vars['user_picture'] = theme('image', array('path' => $filepath, 'alt' => $alt, 'title' => $alt)); } } else { $vars['user_picture'] = '<i class="icon-user"></i>'; } } else { unset($vars['secondary_menu']); $vars['login'] = drupal_get_form('user_login_block'); } // Add Bootstrap $path = libraries_get_path('bootstrap'); drupal_add_css($path . '/css/bootstrap.css'); drupal_add_css($path . '/css/bootstrap-responsive.css'); drupal_add_js($path . '/js/bootstrap.js'); $path = libraries_get_path('font-awesome'); drupal_add_css($path . '/css/font-awesome.css'); }
/** * Override or insert PHPTemplate variables into the templates. */ function framework_preprocess_page(&$vars) { $vars['tabs2'] = menu_secondary_local_tasks(); if (module_exists('path')) { $alias = drupal_get_path_alias(str_replace('/edit', '', $_GET['q'])); if ($alias != $_GET['q']) { $template_filename = 'page'; foreach (explode('/', $alias) as $path_part) { $template_filename = $template_filename . '-' . $path_part; $vars['template_files'][] = $template_filename; } } } }
/** * Override or insert PHPTemplate variables into the templates. */ function phptemplate_preprocess_page(&$vars) { // print_r($vars); $vars['primary_links'] = _opensourcery_primary_links($vars['primary_links']); $vars['secondary_links'] = _opensourcery_secondary_links($vars['secondary_links']); $vars['tabs2'] = menu_secondary_local_tasks(); // Hook into color.module if (module_exists('color')) { _color_page_alter($vars); } // Render the slideshow view for homepage $vars['embedded_slideshow'] = views_embed_view('homeslideshow', 'block_1'); //Reload the javascript into the scripts due to a problem with slideshow. $vars['scripts'] = drupal_get_js(); }
/** * Preprocesses template variables. * @param vars variables for the template */ function phptemplate_preprocess_page(&$vars) { $vars['tabs2'] = menu_secondary_local_tasks(); if (module_exists('color')) { _color_page_alter($vars); } if (module_exists('mobileplugin')) { $vars['styles'] = _mobileplugin_filter_css($vars['css']); $vars['scripts'] = _mobileplugin_filter_js(); $vars['bodyclasses'] = 'mobile' . _mobileplugin_add_class(); $scaled_logo = _mobileplugin_image_scaled($vars['logo'], 30, 30); if (!is_array($scaled_logo)) { $vars['logo'] = $scaled_logo; } } }
/** * Override or insert PHPTemplate variables into the templates. */ function _phptemplate_variables($hook, $vars) { if ($hook != 'page') { return array(); } $vars['tabs'] = menu_primary_local_tasks(); $vars['tabs2'] = menu_secondary_local_tasks(); // Make $front_page variable available $vars['front_page'] = url(); drupal_add_js(path_to_theme() . '/script.js', 'theme'); $scripts = drupal_get_js(); $scripts = str_replace('misc/jquery.js', path_to_theme() . '/jquery.js', $scripts); $vars['scripts'] = $scripts; return $vars; }
/** * Override or insert PHPTemplate variables into the templates. */ function phptemplate_preprocess_page(&$vars) { $vars['tabs2'] = menu_secondary_local_tasks(); // Hook into color.module if (module_exists('color')) { _color_page_alter($vars); } $vars['celebrity_search'] = drupal_get_form('search_celebrity'); // Generate menu tree from source of primary links $vars['primary_links_tree'] = menu_tree(variable_get('menu_primary_links_source', 'primary-links')); }
/** * Override or insert PHPTemplate variables into the templates. */ function openpublish_theme_preprocess_page(&$vars) { // Override core Blog module's breadcrumb if ($vars['node']->type == 'blog') { $breadcrumb = array(l(t('Home'), NULL), l(t('Blogs'), 'blogs')); if ($vars['node']->field_op_author[0]['view']) { $breadcrumb[] = $vars['node']->field_op_author[0]['view']; } $vars['breadcrumb'] = theme('op_breadcrumb', $breadcrumb); } $vars['tabs2'] = menu_secondary_local_tasks(); // Hook into color.module if (module_exists('color')) { _color_page_alter($vars); } }
/** * Override or insert PHPTemplate variables into the templates. */ function _phptemplate_variables($hook, $vars) { if ($hook == 'page') { if ($secondary = menu_secondary_local_tasks()) { $output = '<span class="clear"></span>'; $output .= "<ul class=\"tabs secondary\">\n" . $secondary . "</ul>\n"; $vars['tabs2'] = $output; } // Hook into color.module if (module_exists('color')) { _color_page_alter($vars); } return $vars; } return array(); }
/** * Override or insert PHPTemplate variables into the templates. */ function phptemplate_preprocess_page(&$vars) { $vars['tabs'] = ''; $primary = menu_primary_local_tasks(); if (!empty($primary)) { $vars['tabs'] = '<ul class="arttabs_primary">' . $primary . '</ul>'; } $vars['tabs2'] = ''; $secondary = menu_secondary_local_tasks(); if (!empty($secondary)) { $vars['tabs2'] = '<ul class="arttabs_secondary">' . $secondary . '</ul>'; } // Hook into color.module if (module_exists('color')) { _color_page_alter($vars); } }
/** * Preprocesses template variables. * @param vars variables for the template */ function phptemplate_preprocess_page(&$vars) { global $user; $vars['user'] = $user; $vars['tabs2'] = menu_secondary_local_tasks(); if (module_exists('color')) { // _color_page_alter($vars); } $vars['mode_user'] = false; /* echo "<pre>\n"; print_r($vars); echo "</pre>\n"; die(); */ $vars['logo_img'] = ''; $vars['title'] = $title = drupal_get_title(); if ($vars['logo']) { $vars['logo_img'] = $logo_img = "<img src='" . $vars['logo'] . "' alt='" . $title . "' border='0' />"; $text = $vars['site_name'] ? $logo_img . $text : $logo_img; } // here there used to be a check for the existence of the mobileplugin. Moved down. // everything should be indented back of two spaces // Make sure we have set the proper group IF the theme settings say so if (arg(0) != 'admin') { _netspective_mobile_force_mobile_group(); } if ($user->uid) { $vars['mode_user'] = true; } $vars['header_text_color'] = '#ffffff'; // make sure we are using color if (module_exists('color')) { $header_text_color = theme_get_setting('theme_header_text_color'); $vars['header_text_color'] = $header_text_color; } $vars['doctype'] = _netspective_mobile_get_doctype(); /* $vars['left'] = str_replace('user-login', 'my-user-login', $vars['left']); $vars['left'] = str_replace('user_login', 'my_user_login', $vars['left']); */ $vars['inline_scripts'] = ''; // Theme the breadcrumb }
function _phptemplate_variables($hook, $vars) { $view = get_artx_drupal_view(); $message = $view->get_incorrect_version_message(); if (!empty($message)) { drupal_set_message($message, 'error'); } if ($hook != 'page') { return array(); } $vars['tabs'] = menu_primary_local_tasks(); $vars['tabs2'] = menu_secondary_local_tasks(); $vars['front_page'] = url(); drupal_add_js(path_to_theme() . '/script.js', 'theme'); $scripts = drupal_get_js(); $scripts = str_replace('misc/jquery.js', path_to_theme() . '/jquery.js', $scripts); $vars['scripts'] = $scripts; return $vars; }
/** * Override or insert variables into the page template. */ function Cancilleria_preprocess_page(&$vars) { global $art_style, $art_head; $vars['tabs'] = menu_primary_local_tasks(); $vars['tabs2'] = menu_secondary_local_tasks(); if (isset($vars['node'])) { if (isset($vars['art_style_' . $vars['node']->nid])) { $art_style = $vars['art_style_' . $vars['node']->nid]; } if (isset($vars['art_head_' . $vars['node']->nid])) { $art_head = $vars['art_head_' . $vars['node']->nid]; } } if (isset($vars['art_blocks_head'])) { $art_head .= $vars['art_blocks_head']; } $vars['search_box'] = NULL; if (function_exists('search_box_form_submit')) { $vars['search_box'] = drupal_get_form('search_form'); } }