/[drupal]/contributions/themes/internet_services/template.php
ViewVC logotype

Contents of /contributions/themes/internet_services/template.php

Parent Directory Parent Directory | Revision Log Revision Log | View Revision Graph Revision Graph


Revision 1.17 - (show annotations) (download) (as text)
Thu May 14 06:27:44 2009 UTC (6 months, 2 weeks ago) by hswong3i
Branch: MAIN
CVS Tags: HEAD
Changes since 1.16: +7 -16 lines
File MIME type: text/x-php
- sync with 6.x-2.x-dev.
1 <?php
2 // $Id: template.php,v 1.10.2.5 2009/04/25 06:42:27 hswong3i Exp $
3
4 /**
5 * Return a themed primary menu.
6 */
7 function phptemplate_primary($items = array()) {
8 $menu_options = menu_get_menus();
9 $primary_links = variable_get('menu_primary_links_source', 'primary-links');
10 $output = '<div id="primary-links-region">';
11 $output .= '<div class="title">' . $menu_options[$primary_links] . '</div>';
12 $output .= theme('links', $items, array('class' => 'primary-links'));
13 $output .= '</div>';
14 return $output;
15 }
16
17 /**
18 * Return a themed mission trail.
19 *
20 * @return
21 * a string containing the mission output, or execute PHP code snippet if
22 * mission is enclosed with <?php ?>.
23 */
24 function phptemplate_mission() {
25 $mission = theme_get_setting('mission');
26 if (preg_match('/^<\?php/', $mission)) {
27 $mission = drupal_eval($mission);
28 }
29 else {
30 $mission = filter_xss_admin($mission);
31 }
32 return isset($mission) ? $mission : '';
33 }
34
35 /**
36 * Generates IE CSS links for LTR and RTL languages.
37 */
38 function phptemplate_get_ie_styles() {
39 global $language;
40
41 $iecss = '<link type="text/css" rel="stylesheet" media="all" href="'. base_path() . path_to_theme() .'/fix-ie.css" />';
42 if (defined('LANGUAGE_RTL') && $language->direction == LANGUAGE_RTL) {
43 $iecss .= '<style type="text/css" media="all">@import "'. base_path() . path_to_theme() .'/fix-ie-rtl.css";</style>';
44 }
45
46 return $iecss;
47 }

  ViewVC Help
Powered by ViewVC 1.1.2