Mercurial > defr > drupal > core
comparison modules/system/page.tpl.php @ 1:c1f4ac30525a 6.0
Drupal 6.0
author | Franck Deroche <webmaster@defr.org> |
---|---|
date | Tue, 23 Dec 2008 14:28:28 +0100 |
parents | |
children |
comparison
equal
deleted
inserted
replaced
0:5a113a1c4740 | 1:c1f4ac30525a |
---|---|
1 <?php | |
2 // $Id: page.tpl.php,v 1.11 2008/01/24 09:42:51 goba Exp $ | |
3 | |
4 /** | |
5 * @file page.tpl.php | |
6 * | |
7 * Theme implementation to display a single Drupal page. | |
8 * | |
9 * Available variables: | |
10 * | |
11 * General utility variables: | |
12 * - $base_path: The base URL path of the Drupal installation. At the very | |
13 * least, this will always default to /. | |
14 * - $css: An array of CSS files for the current page. | |
15 * - $directory: The directory the theme is located in, e.g. themes/garland or | |
16 * themes/garland/minelli. | |
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: A set of CSS classes for the BODY tag. This contains flags | |
32 * indicating the current layout (multiple columns, single column), the current | |
33 * path, whether the user is logged in, and so on. | |
34 * | |
35 * Site identity: | |
36 * - $front_page: The URL of the front page. Use this instead of $base_path, | |
37 * when linking to the front page. This includes the language domain or prefix. | |
38 * - $logo: The path to the logo image, as defined in theme configuration. | |
39 * - $site_name: The name of the site, empty when display has been disabled | |
40 * in theme settings. | |
41 * - $site_slogan: The slogan of the site, empty when display has been disabled | |
42 * in theme settings. | |
43 * - $mission: The text of the site mission, empty when display has been disabled | |
44 * in theme settings. | |
45 * | |
46 * Navigation: | |
47 * - $search_box: HTML to display the search box, empty if search has been disabled. | |
48 * - $primary_links (array): An array containing primary navigation links for the | |
49 * site, if they have been configured. | |
50 * - $secondary_links (array): An array containing secondary navigation links for | |
51 * the site, if they have been configured. | |
52 * | |
53 * Page content (in order of occurrance in the default page.tpl.php): | |
54 * - $left: The HTML for the left sidebar. | |
55 * | |
56 * - $breadcrumb: The breadcrumb trail for the current page. | |
57 * - $title: The page title, for use in the actual HTML content. | |
58 * - $help: Dynamic help text, mostly for admin pages. | |
59 * - $messages: HTML for status and error messages. Should be displayed prominently. | |
60 * - $tabs: Tabs linking to any sub-pages beneath the current page (e.g., the view | |
61 * and edit tabs when displaying a node). | |
62 * | |
63 * - $content: The main content of the current Drupal page. | |
64 * | |
65 * - $right: The HTML for the right sidebar. | |
66 * | |
67 * Footer/closing data: | |
68 * - $feed_icons: A string of all feed icons for the current page. | |
69 * - $footer_message: The footer message as defined in the admin settings. | |
70 * - $footer : The footer region. | |
71 * - $closure: Final closing markup from any modules that have altered the page. | |
72 * This variable should always be output last, after all other dynamic content. | |
73 * | |
74 * @see template_preprocess() | |
75 * @see template_preprocess_page() | |
76 */ | |
77 ?> | |
78 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" | |
79 "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> | |
80 <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="<?php print $language->language ?>" lang="<?php print $language->language ?>" dir="<?php print $language->dir ?>"> | |
81 | |
82 <head> | |
83 <title><?php print $head_title; ?></title> | |
84 <?php print $head; ?> | |
85 <?php print $styles; ?> | |
86 <?php print $scripts; ?> | |
87 <script type="text/javascript"><?php /* Needed to avoid Flash of Unstyled Content in IE */ ?> </script> | |
88 </head> | |
89 <body class="<?php print $body_classes; ?>"> | |
90 <div id="page"> | |
91 <div id="header"> | |
92 <div id="logo-title"> | |
93 | |
94 <?php if (!empty($logo)): ?> | |
95 <a href="<?php print $front_page; ?>" title="<?php print t('Home'); ?>" rel="home" id="logo"> | |
96 <img src="<?php print $logo; ?>" alt="<?php print t('Home'); ?>" /> | |
97 </a> | |
98 <?php endif; ?> | |
99 | |
100 <div id="name-and-slogan"> | |
101 <?php if (!empty($site_name)): ?> | |
102 <h1 id="site-name"> | |
103 <a href="<?php print $front_page ?>" title="<?php print t('Home'); ?>" rel="home"><span><?php print $site_name; ?></span></a> | |
104 </h1> | |
105 <?php endif; ?> | |
106 | |
107 <?php if (!empty($site_slogan)): ?> | |
108 <div id="site-slogan"><?php print $site_slogan; ?></div> | |
109 <?php endif; ?> | |
110 </div> <!-- /name-and-slogan --> | |
111 </div> <!-- /logo-title --> | |
112 | |
113 <?php if (!empty($search_box)): ?> | |
114 <div id="search-box"><?php print $search_box; ?></div> | |
115 <?php endif; ?> | |
116 | |
117 <?php if (!empty($header)): ?> | |
118 <div id="header-region"> | |
119 <?php print $header; ?> | |
120 </div> | |
121 <?php endif; ?> | |
122 | |
123 </div> <!-- /header --> | |
124 | |
125 <div id="container" class="clear-block"> | |
126 | |
127 <div id="navigation" class="menu <?php if (!empty($primary_links)) { print "withprimary"; } if (!empty($secondary_links)) { print " withsecondary"; } ?> "> | |
128 <?php if (!empty($primary_links)): ?> | |
129 <div id="primary" class="clear-block"> | |
130 <?php print theme('links', $primary_links, array('class' => 'links primary-links')); ?> | |
131 </div> | |
132 <?php endif; ?> | |
133 | |
134 <?php if (!empty($secondary_links)): ?> | |
135 <div id="secondary" class="clear-block"> | |
136 <?php print theme('links', $secondary_links, array('class' => 'links secondary-links')); ?> | |
137 </div> | |
138 <?php endif; ?> | |
139 </div> <!-- /navigation --> | |
140 | |
141 <?php if (!empty($left)): ?> | |
142 <div id="sidebar-left" class="column sidebar"> | |
143 <?php print $left; ?> | |
144 </div> <!-- /sidebar-left --> | |
145 <?php endif; ?> | |
146 | |
147 <div id="main" class="column"><div id="main-squeeze"> | |
148 <?php if (!empty($breadcrumb)): ?><div id="breadcrumb"><?php print $breadcrumb; ?></div><?php endif; ?> | |
149 <?php if (!empty($mission)): ?><div id="mission"><?php print $mission; ?></div><?php endif; ?> | |
150 | |
151 <div id="content"> | |
152 <?php if (!empty($title)): ?><h1 class="title" id="page-title"><?php print $title; ?></h1><?php endif; ?> | |
153 <?php if (!empty($tabs)): ?><div class="tabs"><?php print $tabs; ?></div><?php endif; ?> | |
154 <?php if (!empty($messages)): print $messages; endif; ?> | |
155 <?php if (!empty($help)): print $help; endif; ?> | |
156 <div id="content-content" class="clear-block"> | |
157 <?php print $content; ?> | |
158 </div> <!-- /content-content --> | |
159 <?php print $feed_icons; ?> | |
160 </div> <!-- /content --> | |
161 | |
162 </div></div> <!-- /main-squeeze /main --> | |
163 | |
164 <?php if (!empty($right)): ?> | |
165 <div id="sidebar-right" class="column sidebar"> | |
166 <?php print $right; ?> | |
167 </div> <!-- /sidebar-right --> | |
168 <?php endif; ?> | |
169 | |
170 </div> <!-- /container --> | |
171 | |
172 <div id="footer-wrapper"> | |
173 <div id="footer"> | |
174 <?php print $footer_message; ?> | |
175 <?php if (!empty($footer)): print $footer; endif; ?> | |
176 </div> <!-- /footer --> | |
177 </div> <!-- /footer-wrapper --> | |
178 | |
179 <?php print $closure; ?> | |
180 | |
181 </div> <!-- /page --> | |
182 | |
183 </body> | |
184 </html> |