/[drupal]/contributions/page.tpl.php
ViewVC logotype

Contents of /contributions/page.tpl.php

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


Revision 1.3 - (show annotations) (download) (as text)
Wed Oct 21 13:39:20 2009 UTC (4 weeks, 6 days ago) by mcrittenden
Branch: MAIN
Changes since 1.2: +192 -87 lines
File MIME type: text/x-php
Initial commit
1 <?php // $Id$
2
3 /**
4 * @file
5 * Theme implementation to display a single Drupal page.
6 *
7 * Available variables:
8 *
9 * General utility variables:
10 * - $base_path: The base URL path of the Drupal installation. At the very
11 * least, this will always default to /.
12 * - $css: An array of CSS files for the current page.
13 * - $directory: The directory the template is located in, e.g. modules/system
14 * or themes/garland.
15 * - $body_classes_array: Array of the body classes. It is flattened
16 * into a string within the variable $classes.
17 * - $is_front: TRUE if the current page is the front page. Used to toggle the mission statement.
18 * - $logged_in: TRUE if the user is registered and signed in.
19 * - $is_admin: TRUE if the user has permission to access administration pages.
20 *
21 * Page metadata:
22 * - $language: (object) The language the site is being displayed in.
23 * $language->language contains its textual representation.
24 * $language->dir contains the language direction. It will either be 'ltr' or 'rtl'.
25 * - $head_title: A modified version of the page title, for use in the TITLE tag.
26 * - $head: Markup for the HEAD section (including meta tags, keyword tags, and
27 * so on).
28 * - $styles: Style tags necessary to import all CSS files for the page.
29 * - $scripts: Script tags necessary to load the JavaScript files and settings
30 * for the page.
31 * - $body_classes: String of classes that can be used to style contextually through
32 * CSS. It should be placed within the <body> tag. When selecting through CSS
33 * it's recommended that you use the body tag, e.g., "body.front". It can be
34 * manipulated through the variable $classes_array from preprocess functions.
35 * The default values can be one or more of the following:
36 * - front: Page is the home page.
37 * - not-front: Page is not the home page.
38 * - logged-in: The current viewer is logged in.
39 * - not-logged-in: The current viewer is not logged in.
40 * - node-type-[node type]: When viewing a single node, the type of that node.
41 * For example, if the node is a "Blog entry" it would result in "node-type-blog".
42 * Note that the machine name will often be in a short form of the human readable label.
43 * The following only apply with the default 'primary' and 'secondary' block regions:
44 * - two-sidebars: When both sidebars have content.
45 * - no-sidebars: When no sidebar content exists.
46 * - one-sidebar and sidebar-primary or sidebar-secondary: A combination of
47 * the two classes when only one of the two sidebars have content.
48 *
49 * Site identity:
50 * - $front_page: The URL of the front page. Use this instead of $base_path,
51 * when linking to the front page. This includes the language domain or prefix.
52 * - $logo: The path to the logo image, as defined in theme configuration.
53 * - $site_name: The name of the site, empty when display has been disabled
54 * in theme settings.
55 * - $site_slogan: The slogan of the site, empty when display has been disabled
56 * in theme settings.
57 * - $mission: The text of the site mission, empty when display has been disabled
58 * in theme settings.
59 *
60 * Navigation:
61 * - $search_box: HTML to display the search box, empty if search has been disabled.
62 * - $primary_links (array): An array containing the Primary menu links for the
63 * site, if they have been configured.
64 * - $secondary_links (array): An array containing the Secondary menu links for
65 * the site, if they have been configured.
66 * - $breadcrumb: The breadcrumb trail for the current page.
67 *
68 * Page content (in order of occurrence in the default page.tpl.php):
69 * - $left: The HTML for the primary sidebar.
70 * - $title: The page title, for use in the actual HTML content.
71 * - $messages: HTML for status and error messages. Should be displayed prominently.
72 * - $tabs: Tabs linking to any sub-pages beneath the current page (e.g., the view
73 * and edit tabs when displaying a node).
74 * - $help: Dynamic help text, mostly for admin pages.
75 * - $content: The main content of the current Drupal page.
76 * - $feed_icons: A string of all feed icons for the current page.
77 * - $right: The HTML for the secondary sidebar.
78 *
79 * Footer/closing data:
80 * - $footer_message: The footer message as defined in the admin settings.
81 * - $footer : The footer region.
82 * - $closure: Final closing markup from any modules that have altered the page.
83 * This variable should always be output last, after all other dynamic content.
84 *
85 * @see template_preprocess()
86 * @see template_preprocess_page()
87 */ ?>
88 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
89 "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
90 <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="<?php echo $language->language ?>" lang="<?php echo $language->language ?>" dir="<?php echo $language->dir ?>">
91
92 <head>
93
94 <title><?php echo $head_title; ?></title>
95
96 <?php echo $head; ?>
97 <?php echo $styles; ?>
98
99 <!--[if lte IE 6]>
100 <style type="text/css" media="all">@import "<?php echo $base_path . path_to_theme() ?>/css/ie6.css";</style>
101 <![endif]-->
102 <!--[if IE 7]>
103 <style type="text/css" media="all">@import "<?php echo $base_path . path_to_theme() ?>/css/ie7.css";</style>
104 <![endif]-->
105
106 <?php echo $scripts; ?>
107
108 </head>
109
110 <body class="<?php echo $body_classes; ?>">
111
112 <!-- PRIMARY LINKS -->
113 <div id="nav">
114 <?php if (!empty($primary_links)): ?>
115 <?php echo theme('links', $primary_links, array('class' => 'links primary-links')); ?>
116 <?php endif; ?>
117 </div>
118
119 <div id="header">
120
121 <!-- SITE NAME -->
122 <?php if (!empty($site_name)): ?>
123 <h1>
124 <a href="<?php echo $front_page ?>" title="<?php echo t('Home'); ?>" rel="home"><span><?php echo $site_name; ?></span></a>
125 </h1>
126 <?php endif; ?>
127
128 <!-- SLOGAN -->
129 <?php if (!empty($site_slogan)): ?>
130 <?php echo $site_slogan; ?>
131 <?php endif; ?>
132
133 </div>
134
135 <div id="content-wrap"><div id="content">
136
137 <div id="sidebar" >
138 <!-- SEARCH -->
139 <?php if($search_box): ?>
140 <?php echo $search_box; ?>
141 <?php endif; ?>
142
143 <!-- RIGHT SIDEBAR REGION -->
144 <?php if ($right): ?>
145 <?php echo $right; ?>
146 <?php endif; ?>
147 </div>
148
149 <div id="main">
150
151 <!-- CONTENT TOP REGION -->
152 <?php if ($content_top): ?>
153 <?php echo $content_top; ?>
154 <?php endif; ?>
155
156 <!-- BREADCRUMB -->
157 <?php echo $breadcrumb; ?>
158
159 <!-- PAGE TITLE -->
160 <?php if ($title): ?>
161 <h1><?php echo $title; ?></h1>
162 <?php endif; ?>
163
164 <!-- STATUS MESSAGES -->
165 <?php echo $messages; ?>
166
167 <!-- HELP TEXT -->
168 <?php echo $help; ?>
169
170 <!-- MENU TABS -->
171 <?php if ($tabs): ?>
172 <div class="tabs"><?php echo $tabs; ?></div>
173 <?php endif; ?>
174
175 <!-- MAIN CONTENT -->
176 <?php echo $content; ?>
177
178 <!-- BOTTOM CONTENT REGION -->
179 <?php if ($content_bottom): ?>
180 <?php echo $content_bottom; ?>
181 <?php endif; ?>
182
183 </div>
184 </div>
185
186 <div id="footer-bottom">
187 <!-- FOOTER -->
188 <?php if(!empty($footer_message) || !empty($footer_block)): ?>
189 <?php echo $footer_message; ?>
190 <?php echo $footer_block; ?>
191 <?php endif; ?>
192 </div></div>
193
194 <!-- CLOSURE - DO NOT DELETE -->
195 <?php echo $closure; ?>
196
197 </body>
198 </html>

  ViewVC Help
Powered by ViewVC 1.1.2