2
// $Id: page.tpl.php,v 1.11 2008/01/24 09:42:51 goba Exp $
7
* Theme implementation to display a single Drupal page.
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.
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
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
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.
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
41
* - $site_slogan: The slogan of the site, empty when display has been disabled
43
* - $mission: The text of the site mission, empty when display has been disabled
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.
53
* Page content (in order of occurrance in the default page.tpl.php):
54
* - $left: The HTML for the left sidebar.
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).
63
* - $content: The main content of the current Drupal page.
65
* - $right: The HTML for the right sidebar.
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.
74
* @see template_preprocess()
75
* @see template_preprocess_page()
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 ?>">
83
<title><?php print $head_title; ?></title>
85
<?php print $styles; ?>
86
<?php print $scripts; ?>
87
<script type="text/javascript"><?php /* Needed to avoid Flash of Unstyled Content in IE */ ?> </script>
89
<body class="<?php print $body_classes; ?>">
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'); ?>" />
100
<div id="name-and-slogan">
101
<?php if (!empty($site_name)): ?>
103
<a href="<?php print $front_page ?>" title="<?php print t('Home'); ?>" rel="home"><span><?php print $site_name; ?></span></a>
107
<?php if (!empty($site_slogan)): ?>
108
<div id="site-slogan"><?php print $site_slogan; ?></div>
110
</div> <!-- /name-and-slogan -->
111
</div> <!-- /logo-title -->
113
<?php if (!empty($search_box)): ?>
114
<div id="search-box"><?php print $search_box; ?></div>
117
<?php if (!empty($header)): ?>
118
<div id="header-region">
119
<?php print $header; ?>
123
</div> <!-- /header -->
125
<div id="container" class="clear-block">
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')); ?>
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')); ?>
139
</div> <!-- /navigation -->
141
<?php if (!empty($left)): ?>
142
<div id="sidebar-left" class="column sidebar">
143
<?php print $left; ?>
144
</div> <!-- /sidebar-left -->
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; ?>
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 -->
162
</div></div> <!-- /main-squeeze /main -->
164
<?php if (!empty($right)): ?>
165
<div id="sidebar-right" class="column sidebar">
166
<?php print $right; ?>
167
</div> <!-- /sidebar-right -->
170
</div> <!-- /container -->
172
<div id="footer-wrapper">
174
<?php print $footer_message; ?>
175
<?php if (!empty($footer)): print $footer; endif; ?>
176
</div> <!-- /footer -->
177
</div> <!-- /footer-wrapper -->
179
<?php print $closure; ?>
181
</div> <!-- /page -->