diff options
author | Dries Buytaert <dries@buytaert.net> | 2005-05-04 18:12:18 +0000 |
---|---|---|
committer | Dries Buytaert <dries@buytaert.net> | 2005-05-04 18:12:18 +0000 |
commit | e274f97c879bff059511472a4d14a3584941393e (patch) | |
tree | afc46696e9c6c3025babe52acd13c4d45cb3d876 | |
parent | 0021293533d2bd9434f4b404b513e6d482069f03 (diff) | |
download | brdo-e274f97c879bff059511472a4d14a3584941393e.tar.gz brdo-e274f97c879bff059511472a4d14a3584941393e.tar.bz2 |
- Removed the Xtemplate engine and added the PHPTemplate engine.
- Converted the Bluemarine theme from XTemplate to PHPTemplate.
- Moved the the Pushbutton theme and the Xtemplate engine to the contributions repository.
48 files changed, 571 insertions, 1514 deletions
diff --git a/CHANGELOG.txt b/CHANGELOG.txt index a0e7575a3..c347a0064 100644 --- a/CHANGELOG.txt +++ b/CHANGELOG.txt @@ -3,6 +3,10 @@ Drupal x.x.x, xxxx-xx-xx (Development version) - added free tagging support (folksonomies). - added a site-wide contact form. +- theme system: + * removed the Xtemplate theme engine. + * added the PHPTemplate theme engine. + * converted the bluemarine theme from XTemplate to PHPTemplate. - reworked the 'request new password' functionality. - profiles: * added a block to display author information along with posts. diff --git a/database/updates.inc b/database/updates.inc index e1e33734e..c969a51c9 100644 --- a/database/updates.inc +++ b/database/updates.inc @@ -2407,6 +2407,24 @@ function update_132() { return $ret; } +function update_130() { + $ret = array(); + + if ($GLOBALS['db_type'] == 'mysql') { + $ret[] = update_sql("ALTER TABLE {locales_source} CHANGE location location varchar(255) NOT NULL default ''"); + } + elseif ($GLOBALS['db_type'] == 'pgsql') { + $ret[] = update_sql("ALTER TABLE {locales_source} RENAME location TO location_old"); + $ret[] = update_sql("ALTER TABLE {locales_source} ADD location varchar(255)"); + $ret[] = update_sql("ALTER TABLE {locales_source} ALTER location SET NOT NULL"); + $ret[] = update_sql("ALTER TABLE {locales_source} ALTER location SET DEFAULT ''"); + $ret[] = update_sql("UPDATE {locales_source} SET location = location_old"); + $ret[] = update_sql("ALTER TABLE {locales_source} DROP location_old"); + } + + return $ret; +} + function update_133() { $ret[] = update_sql("CREATE TABLE {contact} ( subject varchar(255) NOT NULL default '', diff --git a/includes/theme.inc b/includes/theme.inc index a65f8b713..0bc46252a 100644 --- a/includes/theme.inc +++ b/includes/theme.inc @@ -211,8 +211,8 @@ function path_to_theme() { */ function theme_get_settings($key = NULL) { $defaults = array( - 'primary_links' => l(t('edit primary links'), 'admin/themes/settings'), - 'secondary_links' => l(t('edit secondary links'), 'admin/themes/settings'), + 'primary_links' => array(), + 'secondary_links' => array(), 'mission' => '', 'default_logo' => 1, 'logo_path' => '', diff --git a/modules/system.module b/modules/system.module index 59f542491..ae057eed1 100644 --- a/modules/system.module +++ b/modules/system.module @@ -652,9 +652,44 @@ function system_theme_settings($key = '') { // System wide only settings. if (!$key) { // Menu settings - $group = form_textarea(t('Primary links'), "$var][primary_links", $settings['primary_links'], 70, 8, t('The HTML code for the primary links.')); - $group .= form_textarea(t('Secondary links'), "$var][secondary_links", $settings['secondary_links'], 70, 8, t('The HTML code for the secondary links.')); - $form .= form_group(t('Menu Settings'), $group, t('Customize the menus that are displayed at the top and/or bottom of the page. This configuration screen is only available in the site wide display configuration.')); + + $header = array(t('link text'), t('url'), t('description')); + foreach (array('Primary', 'Secondary') as $utype) { + $group = ''; + $rows = array(); + + //Use $utype field , and strtolower() it to get the type field.. to avoid issues with ucfirst() and unicode. + $type = strtolower($utype); + $value = theme_get_setting($type . '_links'); + if (!is_array($value)) { + $value = array(); + } + + //Increment the link count, if the user has requested more links. + if (variable_get($type . '_links_more', false)) { + variable_del($type . '_links_more'); + variable_set($type . '_link_count', variable_get($type . '_link_count', 5) + 5); + } + + //Get the amount of links to show, possibly expanding if there are more links defined than the count specifies. + $count = variable_get($type . '_link_count', 5); + $count = ($count > sizeof($value['link'])) ? $count : sizeof($value['link']); + if (variable_get($type . '_link_count', 5) != $count) { + variable_set($type . '_link_count', $count); + } + + for ($i = 0; $i < $count; $i++) { + $row = array(); + foreach (array('text', 'link', 'description') as $field) { + $row[] = form_textfield('', $var . '][' . $type . '_links][' . $field . '][' . $i, $value[$field][$i], 15, 90); + } + $rows[] = $row; + } + + $group .= form_item('', theme("table", $header, $rows), t('You can specify your _TYPE_ links here, one link per line.<br /> The link text field is the text you want to link.<br /> The url field is the location the link points to.<br /> The description field is an optional description of where the link points.', array('_TYPE_' => $type))); + $group .= form_checkbox(t('I need more _TYPE_ links.', array('_TYPE_' => $type)), $type . '_links_more', 1, FALSE, t('Checking this box will give you 5 additional _TYPE_ links.', array('_TYPE_' => $type))); + $form .= form_group(t('_TYPE_ link settings', array('_TYPE_' => $utype)), $group); + } // Toggle node display. $group = ''; diff --git a/modules/system/system.module b/modules/system/system.module index 59f542491..ae057eed1 100644 --- a/modules/system/system.module +++ b/modules/system/system.module @@ -652,9 +652,44 @@ function system_theme_settings($key = '') { // System wide only settings. if (!$key) { // Menu settings - $group = form_textarea(t('Primary links'), "$var][primary_links", $settings['primary_links'], 70, 8, t('The HTML code for the primary links.')); - $group .= form_textarea(t('Secondary links'), "$var][secondary_links", $settings['secondary_links'], 70, 8, t('The HTML code for the secondary links.')); - $form .= form_group(t('Menu Settings'), $group, t('Customize the menus that are displayed at the top and/or bottom of the page. This configuration screen is only available in the site wide display configuration.')); + + $header = array(t('link text'), t('url'), t('description')); + foreach (array('Primary', 'Secondary') as $utype) { + $group = ''; + $rows = array(); + + //Use $utype field , and strtolower() it to get the type field.. to avoid issues with ucfirst() and unicode. + $type = strtolower($utype); + $value = theme_get_setting($type . '_links'); + if (!is_array($value)) { + $value = array(); + } + + //Increment the link count, if the user has requested more links. + if (variable_get($type . '_links_more', false)) { + variable_del($type . '_links_more'); + variable_set($type . '_link_count', variable_get($type . '_link_count', 5) + 5); + } + + //Get the amount of links to show, possibly expanding if there are more links defined than the count specifies. + $count = variable_get($type . '_link_count', 5); + $count = ($count > sizeof($value['link'])) ? $count : sizeof($value['link']); + if (variable_get($type . '_link_count', 5) != $count) { + variable_set($type . '_link_count', $count); + } + + for ($i = 0; $i < $count; $i++) { + $row = array(); + foreach (array('text', 'link', 'description') as $field) { + $row[] = form_textfield('', $var . '][' . $type . '_links][' . $field . '][' . $i, $value[$field][$i], 15, 90); + } + $rows[] = $row; + } + + $group .= form_item('', theme("table", $header, $rows), t('You can specify your _TYPE_ links here, one link per line.<br /> The link text field is the text you want to link.<br /> The url field is the location the link points to.<br /> The description field is an optional description of where the link points.', array('_TYPE_' => $type))); + $group .= form_checkbox(t('I need more _TYPE_ links.', array('_TYPE_' => $type)), $type . '_links_more', 1, FALSE, t('Checking this box will give you 5 additional _TYPE_ links.', array('_TYPE_' => $type))); + $form .= form_group(t('_TYPE_ link settings', array('_TYPE_' => $utype)), $group); + } // Toggle node display. $group = ''; diff --git a/themes/bluemarine/block.tpl.php b/themes/bluemarine/block.tpl.php new file mode 100644 index 000000000..458a60af6 --- /dev/null +++ b/themes/bluemarine/block.tpl.php @@ -0,0 +1,4 @@ + <div class="block block-<?php print $block->module; ?>" id="block-<?php print $block->module; ?>-<?php print $block->delta; ?>"> + <h2 class="title"><?php print $block->title; ?></h2> + <div class="content"><?php print $block->content; ?></div> + </div> diff --git a/themes/bluemarine/box.tpl.php b/themes/bluemarine/box.tpl.php new file mode 100644 index 000000000..1e5280c3f --- /dev/null +++ b/themes/bluemarine/box.tpl.php @@ -0,0 +1,5 @@ + <div class="box"> + <h2 class="title"><?php print $title; ?></h2> + <div class="content"><?php print $content; ?></div> + </div> + diff --git a/themes/bluemarine/comment.tpl.php b/themes/bluemarine/comment.tpl.php new file mode 100644 index 000000000..be5149c24 --- /dev/null +++ b/themes/bluemarine/comment.tpl.php @@ -0,0 +1,9 @@ + <div class="comment"> + <?php if ($picture) { + print $picture; + } ?> +<h3 class="title"><?php print $title; ?></h3><?php if ($new != '') { ?><span class="new"><?php print $new; ?></span><?php } ?> + <div class="submitted"><?php print $submitted; ?></div> + <div class="content"><?php print $content; ?></div> + <div class="links">» <?php print $links; ?></div> + </div> diff --git a/themes/bluemarine/node.tpl.php b/themes/bluemarine/node.tpl.php new file mode 100644 index 000000000..60ae5dac4 --- /dev/null +++ b/themes/bluemarine/node.tpl.php @@ -0,0 +1,10 @@ + <div class="node<?php if ($sticky) { print " sticky"; } ?>"> + <?php if ($picture) { + print $picture; + }?> + <h2 class="title"><a href="<?php print $node_url?>"><?php print $title?></a></h2> + <span class="submitted"><?php print $submitted?></span> + <span class="taxonomy"><?php print $terms?></span> + <div class="content"><?php print $content?></div> + <div class="links">» <?php print $links?></div> + </div> diff --git a/themes/bluemarine/page.tpl.php b/themes/bluemarine/page.tpl.php new file mode 100644 index 000000000..f8fd5837a --- /dev/null +++ b/themes/bluemarine/page.tpl.php @@ -0,0 +1,63 @@ +<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"><?php global $theme ?> +<html xmlns="http://www.w3.org/1999/xhtml" lang="<?php print $language ?>" xml:lang="<?php print $language ?>"> + +<head> + <title><?php print $head_title ?></title> + <?php print $head ?> + <?php print $styles ?> + <script type="text/javascript"> </script> +</head> + +<body<?php print $onload_attributes ?>> + +<table border="0" cellpadding="0" cellspacing="0" id="header"> + <tr> + <td id="logo"> + + <a href="./" title="Home"><img src="<?php print $logo ?>" alt="Home" border="0" /></a> + <h1 class='site-name'><a href="./" title="Home"><?php print $site_name ?></a></h1> + <div class='site-slogan'><?php print $site_slogan ?></div> + + </td> + <td id="menu"> + <div id="secondary"><?php print (is_array($secondary_links) && count($secondary_links) > 0) ? theme('links', $secondary_links) : l(t('edit secondary links'),'admin/themes/settings') ?></div> + <div id="primary"><?php print (is_array($primary_links) && count($primary_links) > 0) ? theme('links', $primary_links) : l(t('edit primary links'), 'admin/themes/settings') ?></div> + <?php if ($search_box) { ?><form action="<?php print $search_url ?>" method="post"> + <div id="search"> + <input class="form-text" type="text" size="15" value="" name="keys" alt="<?php print $search_description ?>" /> + <input class="form-submit" type="submit" value="<?php print $search_button_text ?>" /> + </div> + </form><?php } ?> + </td> + </tr> +</table> + +<table border="0" cellpadding="0" cellspacing="0" id="content"> + <tr> + <?php if ($sidebar_left) { ?><td id="sidebar-left"> + <?php print $sidebar_left ?> + </td><?php } ?> + <td valign="top"> + <?php if ($mission) { ?><div id="mission"><?php print $mission ?></div><?php } ?> + <div id="main"> + <?php print $breadcrumb ?> + <h1 class="title"><?php print $title ?></h1> + <div class="tabs"><?php print $tabs ?></div> + <div id="help"><?php print $help ?></div> + <?php print $messages ?> + + <?php print $content; ?> + </div> + </td> + <?php if ($sidebar_right) { ?><td id="sidebar-right"> + <?php print $sidebar_right ?> + </td><?php } ?> + </tr> +</table> + +<div id="footer"> + <?php print $footer_message ?> +</div> +<?php print $closure ?> +</body> +</html> diff --git a/themes/bluemarine/style.css b/themes/bluemarine/style.css index 4f6e637d6..366f538d1 100644 --- a/themes/bluemarine/style.css +++ b/themes/bluemarine/style.css @@ -14,7 +14,7 @@ tr.dark td, tr.light td { padding: 0.3em; } h1, h2, h3, h4, h5, h6 { - margin-bottom: 0.5em; + margin: 0.5; } h1 { font-size: 1.3em; @@ -25,10 +25,6 @@ h2 { h3, h4, h5, h6 { font-size: 1.1em; } -p { - margin-top: 0.5em; - margin-bottom: 0.9em; -} a { text-decoration: none; font-weight: bold; @@ -87,7 +83,6 @@ table { #logo img { float: left; padding: 0em 1.0em 0em 1em; - border: 0; } #menu { padding: 0.5em 0.5em 0 0.5em; diff --git a/themes/engines/phptemplate/block.tpl.php b/themes/engines/phptemplate/block.tpl.php new file mode 100644 index 000000000..ca670dbbd --- /dev/null +++ b/themes/engines/phptemplate/block.tpl.php @@ -0,0 +1,4 @@ +<div class="<?php print "block block-$block->module" ?>" id="<?php print "block-$block->module-$block->delta"; ?>"> + <h2><?php print $block->subject ?></h2> + <div class="content"><?php print $block->content ?></div> +</div> diff --git a/themes/engines/phptemplate/box.tpl.php b/themes/engines/phptemplate/box.tpl.php new file mode 100644 index 000000000..e19ffba88 --- /dev/null +++ b/themes/engines/phptemplate/box.tpl.php @@ -0,0 +1,4 @@ +<div class="box"> + <h2><?php print $title ?></h2> + <div class="content"><?php print $content ?></div> +</div> diff --git a/themes/engines/phptemplate/comment.tpl.php b/themes/engines/phptemplate/comment.tpl.php new file mode 100644 index 000000000..69962aeb4 --- /dev/null +++ b/themes/engines/phptemplate/comment.tpl.php @@ -0,0 +1,15 @@ +<div class="comment <?php print ($comment->new) ? 'comment-new' : '' ?>"> +<?php if ($comment->new) : ?> + <a id="new"></a> + <span class="new"><?php print $new ?></span> +<?php endif; ?> + +<div class="title"><?php print $title ?></div> + <?php print $picture ?> + <div class="author"><?php print $submitted ?></div> + <div class="content"><?php print $content ?></div> + <?php if ($picture) : ?> + <br class="clear" /> + <?php endif; ?> + <div class="links"><?php print $links ?></div> +</div> diff --git a/themes/engines/phptemplate/default.tpl.php b/themes/engines/phptemplate/default.tpl.php new file mode 100644 index 000000000..8008a2c12 --- /dev/null +++ b/themes/engines/phptemplate/default.tpl.php @@ -0,0 +1 @@ +<!-- PHPTemplate was instructed to override the <?php print $hook ?> theme function, but no valid template file was found. --> diff --git a/themes/engines/phptemplate/node.tpl.php b/themes/engines/phptemplate/node.tpl.php new file mode 100644 index 000000000..6f00cdb1f --- /dev/null +++ b/themes/engines/phptemplate/node.tpl.php @@ -0,0 +1,18 @@ +<div class="node<?php print ($sticky) ? " sticky" : ""; ?>"> + <?php if ($page == 0): ?> + <h2><a href="<?php print $node_url ?>" title="<?php print $title ?>"><?php print $title ?></a></h2> + <?php endif; ?> + <?php print $picture ?> + + <div class="info"><?php print $submitted ?><span class="terms"><?php print $terms ?></span></div> + <div class="content"> + <?php print $content ?> + </div> +<?php if ($links): ?> + + <?php if ($picture): ?> + <br class='clear' /> + <?php endif; ?> + <div class="links"><?php print $links ?></div> +<?php endif; ?> +</div> diff --git a/themes/engines/phptemplate/phptemplate.engine b/themes/engines/phptemplate/phptemplate.engine new file mode 100644 index 000000000..699762cbe --- /dev/null +++ b/themes/engines/phptemplate/phptemplate.engine @@ -0,0 +1,337 @@ +<?php +// $Id$ + +/** + * @file + * Handles integration of templates written in pure php with the Drupal theme system. + */ + +function phptemplate_init($template) { + $file = dirname($template->filename) . '/template.php'; + if (file_exists($file)) { + include_once($file); + } +} + +function phptemplate_templates($directory = 'themes') { + return system_listing('^page\.tpl\.php$', $directory, 'filename'); +} + +/** + * Execute a template engine call. + * + * Each call to the template engine has two parts. Namely preparing + * the variables, and then doing something with them. + * + * The first step is done by all template engines / themes, the second + * step is dependent on the engine used. + * + * @param $hook + * The name of the theme function being executed. + * @param $variables + * A sequential array of variables passed to the theme function. + * @param $file + * A suggested template file to use. If the file is not found, the default $hook.tpl.php will be used. + * @return + * The HTML generated by the template system. + */ +function _phptemplate_callback($hook, $variables = array(), $file = null) { + + $variables = array_merge($variables, _phptemplate_default_variables($hook, $variables)); + + // Allow specified variables to be overridden + if (function_exists('_phptemplate_variables')) { + $variables = array_merge($variables, _phptemplate_variables($hook, $variables)); + } + + if ($variables['template_file']) { + $file = $variables['template_file']; + } + + if (function_exists('_phptemplate_' . $hook)) { + return call_user_func('_phptemplate_' . $hook, $variables, $file); + } + elseif (function_exists('_phptemplate_default')) { + return call_user_func('_phptemplate_default', $hook, $variables, $file); + } + +} + +/** + * Adds additional helper variables to all templates. + * + * Counts how many times certain hooks have been called. Sidebar left / right are special cases. + * + * @param $hook + * The name of the theme function being executed. + * @param $variables + * A sequential array of variables passed to the theme function. + */ +function _phptemplate_default_variables($hook, $variables) { + static $count = array(); + $count[$hook] = is_int($count[$hook]) ? $count[$hook] : 1; + $variables['zebra'] = ($count[$hook] % 2) ? 'odd' : 'even'; + $variables['id'] = $count[$hook]++; + + global $sidebar_indicator; + if ($hook == 'block') { + $count['block_counter'][$sidebar_indicator] = is_int($count['block_counter'][$sidebar_indicator]) ? $count['block_counter'][$sidebar_indicator] : 1; + $variables['block_zebra'] = ($count['block_counter'][$sidebar_indicator] % 2) ? 'odd' : 'even'; + $variables['block_id'] = $count['block_counter'][$sidebar_indicator]++; + } + + // Tell all templates where they are located. + $variables['directory'] = path_to_theme(); + + if (drupal_get_path_alias($_GET['q']) == variable_get('site_frontpage', 'node')) { + $variables['is_front'] = true; + } + + return $variables; +} + +function phptemplate_features() { + return array( + 'logo', + 'toggle_name', + 'toggle_search', + 'toggle_slogan', + 'toggle_mission', + 'toggle_primary_links', + 'toggle_secondary_links', + 'toggle_node_user_picture', + 'toggle_comment_user_picture'); +} + +/** + * Prepare the values passed to the theme_page function to be passed + * into a pluggable template engine. + */ +function phptemplate_page($content) { + /* Set title and breadcrumb to declared values */ + + if (file_exists(path_to_theme() . '/favicon.ico')) { + drupal_set_html_head("<link rel=\"shortcut icon\" href=\"" . path_to_theme() . "/favicon.ico\" />\n"); + } + + if ($_GET['q'] == variable_get('site_frontpage', 'node')) { + $mission = theme_get_setting('mission'); + $frontpage = true; + } + + $links['primary'] = array(); + $links['secondary'] = array(); + + foreach (array('primary', 'secondary') as $type) { + //Get the data to populate the textfields, if the variable is not an array .. try to parse the old-style link format. + $value = theme_get_setting($type . '_links'); + + //Get the amount of links to show, possibly expanding if there are more links defined than the count specifies. + $count = variable_get($type . '_link_count', 5); + $count = ($count > sizeof($value['link'])) ? $count : sizeof($value['link']); + + if (theme_get_setting('toggle_' . $type . '_links')) { + for ($i =0; $i < $count; $i++) { + unset($attributes); + if (!empty($value['text'][$i])) { + if (!empty($value['description'][$i])) { + $attributes['title'] = $value['description'][$i]; + } + $text = $value['text'][$i]; + $link = $value['link'][$i]; + if (substr($link, 0, 4) == 'http') { + $links[$type][] = '<a href="'. $link .'"'. drupal_attributes($attributes) .'>'. $text .'</a>'; + } + else { + $links[$type][] = l($text, $link, $attributes); + } + } + } + } + } + + /** + * Populate sidebars. + */ + $layout = "none"; + global $sidebar_indicator; + /** + * Sidebar_indicator tells the block counting code to count sidebars seperately. + */ + $sidebar_indicator = 'left'; + $sidebar_left = theme("blocks", "left"); + if ($sidebar_left != "") { + $layout = "left"; + } + + $sidebar_indicator = 'right'; + $sidebar_right = theme("blocks", "right"); + if ($sidebar_right != "") { + $layout = ($layout == "left") ? "both" : "right"; + } + $sidebar_indicator = null; + + $variables = array( + 'head_title' => (drupal_get_title() ? strip_tags(drupal_get_title()) .' | '. variable_get('site_name', 'drupal') : variable_get('site_name', 'drupal') .' | '. variable_get('site_slogan', '')), + 'language' => $GLOBALS['locale'], + 'site' => variable_get('site_name', 'drupal'), + 'head' => drupal_get_html_head(), + 'onload_attributes' => theme('onload_attribute'), + 'logo' => theme_get_setting('logo'), + 'site_name' => (theme_get_setting('toggle_name') ? variable_get('site_name', 'Drupal') : ''), + 'site_slogan' => (theme_get_setting('toggle_slogan') ? variable_get('site_slogan', '') : ''), + 'search_box' => theme_get_setting('toggle_search'), + 'search_url' => url('search'), + 'search_button_text' => t('search'), + 'search_description' => t('Enter the terms you wish to search for.'), + 'title' => drupal_get_title(), + 'primary_links' => $links['primary'], + 'secondary_links' => $links['secondary'], + 'breadcrumb' => theme('breadcrumb', drupal_get_breadcrumb()), + 'tabs' => theme('menu_local_tasks'), + 'messages' => theme('status_messages'), + 'layout' => $layout, + 'help' => theme('help'), + 'styles' => theme_get_styles(), + 'mission' => $mission, + 'sidebar_left' => $sidebar_left, + 'content' => '<!-- begin content -->' . $content . '<!-- end content -->', + 'sidebar_right' => $sidebar_right, + 'footer_message' => variable_get('site_footer', FALSE), + 'closure' => theme('closure') + ); + if ((arg(0) == 'node') && is_int(arg(1))) { + $variables['node'] = node_load(array('nid' => arg(1))); + } + + return _phptemplate_callback('page', $variables); +} + +/** + * Prepare the values passed to the theme_node function to be passed + * into a pluggable template engine. + */ +function phptemplate_node($node, $main = 0, $page = 0) { + if (module_exist('taxonomy')) { + $taxonomy = taxonomy_link('taxonomy terms', $node); + } + else { + $taxonomy = array(); + } + + $variables = array( + 'title' => check_plain($node->title), + 'node_url' => url('node/' . $node->nid), + 'terms' => theme('links',$taxonomy), + 'name' => format_name($node), + 'date' => format_date($node->created), + 'sticky' => $node->sticky, + 'picture' => theme_get_setting('toggle_node_user_picture') ? theme('user_picture', $node) : '', + 'content' => ($main && $node->teaser) ? $node->teaser : $node->body, + 'links' => $node->links ? theme('links', $node->links) : '', + 'mission' => $mission, + 'page' => $page, + 'taxonomy' => $taxonomy, + + /* Lastly , pass the actual node to allow more customization */ + 'node' => $node, + 'main' => $main, + 'page' => $page + ); + + // Display info only on certain node types. + if (theme_get_setting('toggle_node_info_' . $node->type)) { + $variables['submitted'] = t('Submitted by %a on %b.', array('%a' => format_name($node), '%b' => format_date($node->created))); + } + + return _phptemplate_callback('node', $variables, 'node-' . $node->type); +} + +/** + * Prepare the values passed to the theme_comment function to be passed + * into a pluggable template engine. + */ +function phptemplate_comment($comment, $links = 0) { + return _phptemplate_callback('comment', array( + 'new' => $comment->new ? t('new') : '', + 'comment' => $comment, + 'submitted' => t('Submitted by %a on %b.', + array('%a' => format_name($comment), + '%b' => format_date($comment->timestamp))), + 'title' => l($comment->subject, $_GET['q'], NULL, NULL, "comment-$comment->cid"), + + 'picture' => theme_get_setting('toggle_comment_user_picture') ? theme('user_picture', $comment) : '', + 'links' => $links, + 'content' => $comment->comment, + 'author' => format_name($comment), + 'date' => format_date($comment->timestamp) + )); +} + +/** + * Prepare the values passed to the theme_block function to be passed + * into a pluggable template engine. + */ +function phptemplate_block($block) { + return _phptemplate_callback('block', array('block' => $block)); +} + +/** + * Prepare the values passed to the theme_box function to be passed + * into a pluggable template engine. + */ +function phptemplate_box($title, $content, $region = 'main') { + return _phptemplate_callback('box', array( + 'title' => $title, + 'content' => $content, + 'region' => $region + )); +} + +/** + * Default callback for PHPTemplate. + * + * Load a template file, and pass the variable array to it. + * If the suggested file is not found, PHPTemplate will attempt to use + * a $hook.tpl.php file in the template directory, and failing that a + * $hook.tpl.php in the PHPTemplate directory. + * + * @param $hook + * The name of the theme function being executed. + * @param $variables + * A sequential array of variables passed to the theme function. + * @param $file + * A suggested template file to use. + */ +function _phptemplate_default($hook, $variables, $file = null) { + if ($file && file_exists(path_to_theme() . "/$file.tpl.php")) { + $file = path_to_theme() . "/$file.tpl.php"; + } + else { + if (file_exists(path_to_theme() . "/$hook.tpl.php")) { + $file = path_to_theme() . "/$hook.tpl.php"; + } + else { + if (in_array($hook, array('node', 'block', 'box', 'comment'))) { + $file = "themes/engines/phptemplate/$hook.tpl.php"; + } + else { + $variables['hook'] = $hook; + watchdog('error', 'PHPTemplate was instructed to override the ' . $hook . ' theme function, but no valid template file was found.'); + $file = "themes/engines/phptemplate/default.tpl.php"; + } + } + } + + if ($file) { + extract($variables); // Extract the vars to local namespace + ob_start(); // Start output buffering + include($file); // Include the file + $contents = ob_get_contents(); // Get the contents of the buffer + ob_end_clean(); // End buffering and discard + return $contents; // Return the contents + } + +} + +?> diff --git a/themes/engines/xtemplate/xtemplate.engine b/themes/engines/xtemplate/xtemplate.engine deleted file mode 100644 index cab654f5e..000000000 --- a/themes/engines/xtemplate/xtemplate.engine +++ /dev/null @@ -1,236 +0,0 @@ -<?php -// $Id$ - -/** - * @file - * Handles the interface between XTemplate files and the Drupal theme system. - */ - -// Initialize the xtemplate engine. -function xtemplate_init($template) { - // We cannot use the theme() or path_to_theme() functions here - if (!class_exists('XTemplate')) { - include_once(dirname(__FILE__) . '/xtemplate.inc'); - } - $GLOBALS["xtemplate"] = new StdClass(); - $dir = dirname($template->filename); - $GLOBALS['xtemplate']->template = new XTemplate(basename($template->filename), $dir); - $GLOBALS['xtemplate']->template->assign(array('directory' => $dir)); - $GLOBALS['xtemplate']->template->SetNullBlock(' '); // '' doesn't work! -} - -function xtemplate_templates() { - return system_listing('^xtemplate\.xtmpl$', 'themes', 'filename'); -} - -function xtemplate_features() { - return array( - 'logo', - 'toggle_name', - 'toggle_search', - 'toggle_slogan', - 'toggle_mission', - 'toggle_primary_links', - 'toggle_secondary_links', - 'toggle_node_user_picture', - 'toggle_comment_user_picture'); -} - -function xtemplate_node($node, $main = 0, $page = 0) { - global $xtemplate; - - $xtemplate->template->assign(array( - "submitted" => theme_get_setting("toggle_node_info_$node->type") ? - t("Submitted by %a on %b.", - array("%a" => format_name($node), - "%b" => format_date($node->created))) : '', - "link" => url("node/$node->nid"), - "title" => check_plain($node->title), - "author" => format_name($node), - "date" => format_date($node->created), - "sticky" => ($main && $node->sticky) ? 'sticky' : '', - "content" => ($main && $node->teaser) ? $node->teaser : $node->body)); - - if ($page == 0) { - $xtemplate->template->parse("node.title"); - } - - if (theme_get_setting('toggle_node_user_picture') && $picture = theme('user_picture', $node)) { - $xtemplate->template->assign("picture", $picture); - $xtemplate->template->parse("node.picture"); - } - - if (module_exist("taxonomy") && ($taxonomy = taxonomy_link("taxonomy terms", $node))) { - $xtemplate->template->assign("taxonomy", theme_links($taxonomy)); - $xtemplate->template->parse("node.taxonomy"); - } - - if ($node->links) { - $xtemplate->template->assign("links", theme_links($node->links)); - $xtemplate->template->parse("node.links"); - } - - $xtemplate->template->parse("node"); - $output = $xtemplate->template->text("node"); - $xtemplate->template->reset("node"); - return $output; -} - -function xtemplate_comment($comment, $links = 0) { - global $xtemplate; - - $xtemplate->template->assign(array ( - "new" => t("new"), - "submitted" => t("Submitted by %a on %b.", - array("%a" => format_name($comment), - "%b" => format_date($comment->timestamp))), - "title" => l($comment->subject, $_GET['q'], NULL, NULL, "comment-$comment->cid"), - "author" => format_name($comment), - "date" => format_date($comment->timestamp), - "content" => $comment->comment - )); - - if ($comment->new) { - $xtemplate->template->parse("comment.new"); - } - - if (theme_get_setting('toggle_comment_user_picture') && $picture = theme('user_picture', $comment)) { - $xtemplate->template->assign("picture", $picture); - $xtemplate->template->parse("comment.picture"); - } - - if ($links) { - $xtemplate->template->assign("links", $links); - $xtemplate->template->parse("comment.links"); - } - - $xtemplate->template->parse("comment"); - $output = $xtemplate->template->text("comment"); - $xtemplate->template->reset("comment"); - - return $output; -} - -function xtemplate_page($content) { - global $xtemplate; - - $xtemplate->template->assign(array( - "language" => $GLOBALS['locale'], - "head_title" => (drupal_get_title() ? strip_tags(drupal_get_title()) ." | ". variable_get("site_name", "drupal") : variable_get("site_name", "drupal") ." | ". variable_get("site_slogan", "")), - "head" => drupal_get_html_head(), - "styles" => theme_get_styles(), - "onload_attributes" => theme_onload_attribute(), - "primary_links" => theme_get_setting('primary_links'), - "secondary_links" => theme_get_setting('secondary_links') - )); - - if ($logo = theme_get_setting('logo')) { - $xtemplate->template->assign('logo', $logo); - $xtemplate->template->parse('header.logo'); - } - - if (theme_get_setting('toggle_name')) { - $xtemplate->template->assign('site_name', variable_get('site_name', '')); - $xtemplate->template->parse('header.site_name'); - } - - if (theme_get_setting('toggle_slogan')) { - $xtemplate->template->assign('site_slogan', variable_get('site_slogan', '')); - $xtemplate->template->parse('header.site_slogan'); - } - - if ($tabs = theme('menu_local_tasks')) { - $xtemplate->template->assign("tabs", $tabs); - $xtemplate->template->parse("header.title.tabs"); - } - - if ($title = drupal_get_title()) { - $xtemplate->template->assign("title", $title); - $xtemplate->template->assign("breadcrumb", theme("breadcrumb", drupal_get_breadcrumb())); - $xtemplate->template->parse("header.title"); - } - - if ($help = theme('help')) { - $xtemplate->template->assign("help", $help); - $xtemplate->template->parse("header.help"); - } - - if ($message = theme('status_messages')) { - $xtemplate->template->assign("message", $message); - $xtemplate->template->parse("header.message"); - } - - if (theme_get_setting('toggle_search')) { - $xtemplate->template->assign(array( - //"search" => search_form(), - "search_url" => url("search"), - "search_button_text" => t("Search"), - "search_description" => t("Enter the terms you wish to search for.") - )); - $xtemplate->template->parse("header.search_box"); - } - - // only parse the mission block if we are on the frontpage ... - if ($_GET["q"] == variable_get("site_frontpage", "node") && theme_get_setting('toggle_mission') && ($mission = theme_get_setting('mission'))) { - $xtemplate->template->assign("mission", $mission); - $xtemplate->template->parse("header.mission"); - } - - if ($blocks = theme("blocks", "left")) { - $xtemplate->template->assign("blocks", $blocks); - $xtemplate->template->parse("header.blocks"); - } - - $xtemplate->template->parse("header"); - $output = $xtemplate->template->text("header"); - - $output .= "\n<!-- begin content -->\n"; - $output .= $content; - $output .= "\n<!-- end content -->\n"; - - if ($blocks = theme("blocks", "right")) { - $xtemplate->template->assign("blocks", $blocks); - $xtemplate->template->parse("footer.blocks"); - } - - // only parse the footer block if site_footer is set - if ($footer_message = variable_get("site_footer", FALSE)) { - $xtemplate->template->assign("footer_message", $footer_message); - $xtemplate->template->parse("footer.message"); - } - - $xtemplate->template->assign("footer", theme_closure()); - $xtemplate->template->parse("footer"); - - $output .= $xtemplate->template->text("footer"); - - return $output; -} - -function xtemplate_block(&$block) { - global $xtemplate; - - // create template variables for all block variables (module, delta, region, subject, content, ...) - foreach ($block as $key => $value) { - $xtemplate->template->assign($key == "subject" ? "title" : $key, $value); // TODO: standardize on 'title' (ie. rename all $block["subject"] to "title") - } - $xtemplate->template->parse("block"); - $output = $xtemplate->template->text("block"); - $xtemplate->template->reset("block"); - return $output; -} - -function xtemplate_box($title, $content, $region = "main") { - global $xtemplate; - - $xtemplate->template->assign(array( - "title" => $title, - "content" => $content)); - - $xtemplate->template->parse("box"); - $output = $xtemplate->template->text("box"); - $xtemplate->template->reset("box"); - return $output; -} - -?> diff --git a/themes/engines/xtemplate/xtemplate.inc b/themes/engines/xtemplate/xtemplate.inc deleted file mode 100644 index 6c89be93d..000000000 --- a/themes/engines/xtemplate/xtemplate.inc +++ /dev/null @@ -1,480 +0,0 @@ -<?php - -class XTemplate { - -/* - xtemplate class 0.3pre - html generation with templates - fast & easy - copyright (c) 2000-2001 Barnabas Debreceni [cranx@users.sourceforge.net] - - contributors: - Ivar Smolin <okul@linux.ee> (14-march-2001) - - made some code optimizations - Bert Jandehoop <bert.jandehoop@users.info.wau.nl> (26-june-2001) - - new feature to substitute template files by other templates - - new method array_loop() - - !!! {FILE {VAR}} file variable interpolation may still be buggy !!! - - latest stable & CVS versions always available @ - http://sourceforge.net/projects/xtpl/ - - This program is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public License - version 2.1 as published by the Free Software Foundation. - - This library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU Lesser General Public License for more details at - http://www.gnu.org/copyleft/lgpl.html - - You should have received a copy of the GNU General Public License - along with this program; if not, write to the Free Software - Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. - - $Id$ - -*/ - -/***[ variables ]***********************************************************/ - -var $filecontents=""; /* raw contents of template file */ -var $blocks=array(); /* unparsed blocks */ -var $parsed_blocks=array(); /* parsed blocks */ -var $preparsed_blocks=array(); /* preparsed blocks, for file includes */ -var $block_parse_order=array(); /* block parsing order for recursive parsing (sometimes reverse:) */ -var $sub_blocks=array(); /* store sub-block names for fast resetting */ -var $VARS=array(); /* variables array */ -var $FILEVARS=array(); /* file variables array */ -var $filevar_parent=array(); /* filevars' parent block */ -var $filecache=array(); /* file caching */ - -var $tpldir=""; /* location of template files */ -var $FILES=null; /* file names lookup table */ - -var $file_delim="/\{FILE\s*\"([^\"]+)\"\s*\}/m"; /* regexp for file includes */ -var $filevar_delim="/\{FILE\s*\{([A-Za-z0-9\._]+?)\}\s*\}/m"; /* regexp for file includes */ -var $filevar_delim_nl="/^\s*\{FILE\s*\{([A-Za-z0-9\._]+?)\}\s*\}\s*\n/m"; /* regexp for file includes w/ newlines */ -var $block_start_delim="<!-- "; /* block start delimiter */ -var $block_end_delim="-->"; /* block end delimiter */ -var $block_start_word="BEGIN:"; /* block start word */ -var $block_end_word="END:"; /* block end word */ - -/* this makes the delimiters look like: <!-- BEGIN: block_name --> if you use my syntax. */ - -var $NULL_STRING=array(""=>""); /* null string for unassigned vars */ -var $NULL_BLOCK=array(""=>""); /* null string for unassigned blocks */ -var $mainblock="main"; -var $ERROR=""; -var $AUTORESET=1; /* auto-reset sub blocks */ - -/***[ constructor ]*********************************************************/ - - -function XTemplate ($file,$tpldir="",$files=null,$mainblock="main") { - $this->tpldir = $tpldir; - if (gettype($files)=="array") - $this->FILES = $files; - $this->mainblock=$mainblock; - $this->filecontents=$this->r_getfile($file); /* read in template file */ - $this->blocks=$this->maketree($this->filecontents,""); /* preprocess some stuff */ - $this->filevar_parent=$this->store_filevar_parents($this->blocks); - $this->scan_globals(); -} - - -/***************************************************************************/ -/***[ public stuff ]********************************************************/ -/***************************************************************************/ - -/***[ assign ]**************************************************************/ -/* - assign a variable -*/ - -function assign ($name,$val="") { - if (gettype($name)=="array") - foreach ($name as $k=>$v) - $this->VARS[$k]=$v; - else - $this->VARS[$name]=$val; -} - -/***[ assign_file ]*********************************************************/ -/* - assign a file variable -*/ - -function assign_file ($name,$val="") { - if (gettype($name)=="array") - foreach ($name as $k=>$v) - $this->assign_file_($k,$v); - else - $this->assign_file_($name,$val); -} - -function assign_file_ ($name,$val) { - if (isset($this->filevar_parent[$name])) { - if ($val!="") { - $val=$this->r_getfile($val); - foreach($this->filevar_parent[$name] as $parent) { - if (isset($this->preparsed_blocks[$parent]) and !isset($this->FILEVARS[$name])) - $copy=$this->preparsed_blocks[$parent]; - else if (isset($this->blocks[$parent])) - $copy=$this->blocks[$parent]; - preg_match_all($this->filevar_delim,$copy,$res,PREG_SET_ORDER); - foreach ($res as $v) { - $copy=preg_replace("/".preg_quote($v[0])."/","$val",$copy); - $this->preparsed_blocks=array_merge($this->preparsed_blocks,$this->maketree($copy,$parent)); - $this->filevar_parent=array_merge($this->filevar_parent,$this->store_filevar_parents($this->preparsed_blocks)); - } - } - } - } - $this->FILEVARS[$name]=$val; -} - -/***[ parse ]***************************************************************/ -/* - parse a block -*/ - -function parse ($bname) { - - if (isset($this->preparsed_blocks[$bname])) { - $copy=$this->preparsed_blocks[$bname]; - } - else if (isset($this->blocks[$bname])) - $copy=$this->blocks[$bname]; - else - $this->set_error ("parse: blockname [$bname] does not exist"); - - /* from there we should have no more {FILE } directives */ - $copy=preg_replace($this->filevar_delim_nl,"",$copy); - - /* find & replace variables+blocks */ - preg_match_all("/\{([A-Za-z0-9\._]+?)}/",$copy,$var_array); - $var_array=$var_array[1]; - foreach ($var_array as $k=>$v) { - $sub=explode(".",$v); - if ($sub[0]=="_BLOCK_") { - unset($sub[0]); - $bname2=implode(".",$sub); - $var=$this->parsed_blocks[$bname2]; - $nul=(!isset($this->NULL_BLOCK[$bname2])) ? $this->NULL_BLOCK[""] : $this->NULL_BLOCK[$bname2]; - if ($var=="") { - if ($nul=="") { - $copy=preg_replace("/^\s*\{".$v."\}\s*\n*/m","",$copy); - } else { - $copy=preg_replace("/\{".$v."\}/","$nul",$copy); - } - } else { - $var=trim($var); - $copy=str_replace("\{$v}","$var",$copy); - } - } else { - $var=$this->VARS; - foreach ($sub as $v1) - $var=$var[$v1]; - $nul=(!isset($this->NULL_STRING[$v])) ? ($this->NULL_STRING[""]) : ($this->NULL_STRING[$v]); - $var=(!isset($var))?$nul:$var; - if ($var=="") - $copy=preg_replace("/^\s*\{".$v."\}\s*\n/m","",$copy); - $copy=str_replace("\{$v}","$var",$copy); - } - } - if (empty($this->parsed_blocks[$bname])) $this->parsed_blocks[$bname] = null; // eliminates incremental assign error, when using E_ALL error reporting - $this->parsed_blocks[$bname].=$copy; - - /* reset sub-blocks */ - if ($this->AUTORESET && (!empty($this->sub_blocks[$bname]))) { - reset($this->sub_blocks[$bname]); - foreach ($this->sub_blocks[$bname] as $k=>$v) - $this->reset($v); - } -} - -/***[ rparse ]**************************************************************/ -/* - returns the parsed text for a block, including all sub-blocks. -*/ - -function rparse($bname) { - if (!empty($this->sub_blocks[$bname])) { - reset($this->sub_blocks[$bname]); - foreach ($this->sub_blocks[$bname] as $k=>$v) - if (!empty($v)) - $this->rparse($v); - } - $this->parse($bname); -} - -/***[ insert_loop ]*********************************************************/ -/* - inserts a loop ( call assign & parse ) -*/ - -function insert_loop($bname,$var,$value="") { - $this->assign($var,$value); - $this->parse($bname); -} - -/***[ array_loop ]*********************************************************/ -/* - parses a block for every set of data in the values array -*/ - -function array_loop($bname, $var, &$values) -{ - if (gettype($values)=="array") - { - foreach($values as $v) - { - $this->assign($var, $v); - $this->parse($bname); - } - } -} - -/***[ text ]****************************************************************/ -/* - returns the parsed text for a block -*/ - -function text($bname) { - return $this->parsed_blocks[isset($bname) ? $bname :$this->mainblock]; -} - -/***[ out ]*****************************************************************/ -/* - prints the parsed text -*/ - -function out ($bname) { - $length=strlen($this->text($bname)); - header("Content-Length: ".$length); - echo $this->text($bname); -} - -/***[ reset ]***************************************************************/ -/* - resets the parsed text -*/ - -function reset ($bname) { - $this->parsed_blocks[$bname]=""; -} - -/***[ parsed ]**************************************************************/ -/* - returns true if block was parsed, false if not -*/ - -function parsed ($bname) { - return (!empty($this->parsed_blocks[$bname])); -} - -/***[ SetNullString ]*******************************************************/ -/* - sets the string to replace in case the var was not assigned -*/ - -function SetNullString($str,$varname="") { - $this->NULL_STRING[$varname]=$str; -} - -/***[ SetNullBlock ]********************************************************/ -/* - sets the string to replace in case the block was not parsed -*/ - -function SetNullBlock($str,$bname="") { - $this->NULL_BLOCK[$bname]=$str; -} - -/***[ set_autoreset ]*******************************************************/ -/* - sets AUTORESET to 1. (default is 1) - if set to 1, parse() automatically resets the parsed blocks' sub blocks - (for multiple level blocks) -*/ - -function set_autoreset() { - $this->AUTORESET=1; -} - -/***[ clear_autoreset ]*****************************************************/ -/* - sets AUTORESET to 0. (default is 1) - if set to 1, parse() automatically resets the parsed blocks' sub blocks - (for multiple level blocks) -*/ - -function clear_autoreset() { - $this->AUTORESET=0; -} - -/***[ scan_globals ]********************************************************/ -/* - scans global variables -*/ - -function scan_globals() { - reset($GLOBALS); - foreach ($GLOBALS as $k=>$v) - $GLOB[$k]=$v; - $this->assign("PHP",$GLOB); /* access global variables as {PHP.HTTP_HOST} in your template! */ -} - -/****** - - WARNING - PUBLIC FUNCTIONS BELOW THIS LINE DIDN'T GET TESTED - -******/ - - -/***************************************************************************/ -/***[ private stuff ]*******************************************************/ -/***************************************************************************/ - -/***[ maketree ]************************************************************/ -/* - generates the array containing to-be-parsed stuff: - $blocks["main"],$blocks["main.table"],$blocks["main.table.row"], etc. - also builds the reverse parse order. -*/ - - -function maketree($con,$parentblock="") { - $blocks=array(); - $con2=explode($this->block_start_delim,$con); - if (!empty($parentblock)) { - $block_names=explode(".",$parentblock); - $level=sizeof($block_names); - } else { - $block_names=array(); - $level=0; - } - foreach ($con2 as $k=>$v) { - $patt="($this->block_start_word|$this->block_end_word)\s*(\w+)\s*$this->block_end_delim(.*)"; - if (preg_match_all("/$patt/ims",$v,$res,PREG_SET_ORDER)) { - // $res[0][1] = BEGIN or END - // $res[0][2] = block name - // $res[0][3] = kinda content - if ($res[0][1]==$this->block_start_word) { - $parent_name=implode(".",$block_names); - $block_names[++$level]=$res[0][2]; /* add one level - array("main","table","row")*/ - $cur_block_name=implode(".",$block_names); /* make block name (main.table.row) */ - $this->block_parse_order[]=$cur_block_name; /* build block parsing order (reverse) */ - if (empty($blocks[$cur_block_name])) $blocks[$cur_block_name] = null; // eliminates incremental assign error, when using E_ALL error reporting - $blocks[$cur_block_name].=$res[0][3]; /* add contents */ - $blocks[$parent_name].="{_BLOCK_.$cur_block_name}"; /* add {_BLOCK_.blockname} string to parent block */ - $this->sub_blocks[$parent_name][]=$cur_block_name; /* store sub block names for autoresetting and recursive parsing */ - $this->sub_blocks[$cur_block_name][]=""; /* store sub block names for autoresetting */ - } else if ($res[0][1]==$this->block_end_word) { - unset($block_names[$level--]); - $parent_name=implode(".",$block_names); - $blocks[$parent_name].=$res[0][3]; /* add rest of block to parent block */ - } - } else { /* no block delimiters found */ - if ($k) - $blocks[implode(".",$block_names)].=$this->block_start_delim; - if (empty($blocks[implode(".",$block_names)])) $blocks[implode(".",$block_names)] = null; // eliminates incremental assign error, when using E_ALL error reporting - $blocks[implode(".",$block_names)].=$v; - } - } - return $blocks; -} - -/***[ store_filevar_parents ]***********************************************/ -/* - store container block's name for file variables -*/ - -function store_filevar_parents($blocks){ - $parents=array(); - foreach ($blocks as $bname=>$con) { - preg_match_all($this->filevar_delim,$con,$res); - foreach ($res[1] as $k=>$v) - $parents[$v][]=$bname; - } - return $parents; -} - -/***[ error stuff ]*********************************************************/ -/* - sets and gets error -*/ - -function get_error() { - return ($this->ERROR=="")?0:$this->ERROR; -} - - -function set_error($str) { - $this->ERROR="<strong>[XTemplate]</strong> <i>".$str."</i>"; - trigger_error($this->get_error()); -} - -/***[ getfile ]*************************************************************/ -/* - returns the contents of a file -*/ - -function getfile($file) { - if (!isset($file)) { - $this->set_error("!isset file name!"); - return ""; - } - - // check if filename is mapped to other filename - if (isset($this->FILES)) - { - if (isset($this->FILES[$file])) - $file = $this->FILES[$file]; - } - // prepend template dir - if (!empty($this->tpldir)) - $file = $this->tpldir."/".$file; - - if (isset($this->filecache[$file])) - $file_text=$this->filecache[$file]; - else { - if (is_file($file)) { - if (!($fh=fopen($file,"r"))) { - $this->set_error("Cannot open file: $file"); - return ""; - } - - $file_text=fread($fh,filesize($file)); - fclose($fh); - } else { - $this->set_error("[$file] does not exist"); - $file_text="<strong>__XTemplate fatal error: file [$file] does not exist__</strong>"; - } - $this->filecache[$file]=$file_text; - } - return $file_text; -} - -/***[ r_getfile ]***********************************************************/ -/* - recursively gets the content of a file with {FILE "filename.tpl"} directives -*/ - - -function r_getfile($file) { - $text=$this->getfile($file); - while (preg_match($this->file_delim,$text,$res)) { - $text2=$this->getfile($res[1]); - $text=preg_replace("'".preg_quote($res[0])."'",$text2,$text); - } - - return $text; -} - - -} /* end of XTemplate class. */ -?> diff --git a/themes/pushbutton/arrow-next-hover.png b/themes/pushbutton/arrow-next-hover.png Binary files differdeleted file mode 100644 index 5e32cd264..000000000 --- a/themes/pushbutton/arrow-next-hover.png +++ /dev/null diff --git a/themes/pushbutton/arrow-next-visited.png b/themes/pushbutton/arrow-next-visited.png Binary files differdeleted file mode 100644 index 392801475..000000000 --- a/themes/pushbutton/arrow-next-visited.png +++ /dev/null diff --git a/themes/pushbutton/arrow-next.png b/themes/pushbutton/arrow-next.png Binary files differdeleted file mode 100644 index cf3ae6aa1..000000000 --- a/themes/pushbutton/arrow-next.png +++ /dev/null diff --git a/themes/pushbutton/arrow-prev-hover.png b/themes/pushbutton/arrow-prev-hover.png Binary files differdeleted file mode 100644 index cd85f90da..000000000 --- a/themes/pushbutton/arrow-prev-hover.png +++ /dev/null diff --git a/themes/pushbutton/arrow-prev-visited.png b/themes/pushbutton/arrow-prev-visited.png Binary files differdeleted file mode 100644 index 38f6e315b..000000000 --- a/themes/pushbutton/arrow-prev-visited.png +++ /dev/null diff --git a/themes/pushbutton/arrow-prev.png b/themes/pushbutton/arrow-prev.png Binary files differdeleted file mode 100644 index e6764ec5c..000000000 --- a/themes/pushbutton/arrow-prev.png +++ /dev/null diff --git a/themes/pushbutton/arrow-up-hover.png b/themes/pushbutton/arrow-up-hover.png Binary files differdeleted file mode 100644 index 3bff73543..000000000 --- a/themes/pushbutton/arrow-up-hover.png +++ /dev/null diff --git a/themes/pushbutton/arrow-up-visited.png b/themes/pushbutton/arrow-up-visited.png Binary files differdeleted file mode 100644 index 2df0fdd23..000000000 --- a/themes/pushbutton/arrow-up-visited.png +++ /dev/null diff --git a/themes/pushbutton/arrow-up.png b/themes/pushbutton/arrow-up.png Binary files differdeleted file mode 100644 index 81dd41032..000000000 --- a/themes/pushbutton/arrow-up.png +++ /dev/null diff --git a/themes/pushbutton/background.png b/themes/pushbutton/background.png Binary files differdeleted file mode 100644 index 889e1cc9a..000000000 --- a/themes/pushbutton/background.png +++ /dev/null diff --git a/themes/pushbutton/forum-container.jpg b/themes/pushbutton/forum-container.jpg Binary files differdeleted file mode 100644 index 46ea78f2a..000000000 --- a/themes/pushbutton/forum-container.jpg +++ /dev/null diff --git a/themes/pushbutton/forum-link.png b/themes/pushbutton/forum-link.png Binary files differdeleted file mode 100644 index 56c50b16e..000000000 --- a/themes/pushbutton/forum-link.png +++ /dev/null diff --git a/themes/pushbutton/header-a.jpg b/themes/pushbutton/header-a.jpg Binary files differdeleted file mode 100644 index 26b6c0122..000000000 --- a/themes/pushbutton/header-a.jpg +++ /dev/null diff --git a/themes/pushbutton/header-b.jpg b/themes/pushbutton/header-b.jpg Binary files differdeleted file mode 100644 index 17ed8541c..000000000 --- a/themes/pushbutton/header-b.jpg +++ /dev/null diff --git a/themes/pushbutton/header-c.png b/themes/pushbutton/header-c.png Binary files differdeleted file mode 100644 index 711a3c7e4..000000000 --- a/themes/pushbutton/header-c.png +++ /dev/null diff --git a/themes/pushbutton/icon-block.png b/themes/pushbutton/icon-block.png Binary files differdeleted file mode 100644 index c12933bef..000000000 --- a/themes/pushbutton/icon-block.png +++ /dev/null diff --git a/themes/pushbutton/icon-comment.png b/themes/pushbutton/icon-comment.png Binary files differdeleted file mode 100644 index 9ef36deda..000000000 --- a/themes/pushbutton/icon-comment.png +++ /dev/null diff --git a/themes/pushbutton/logo-active.jpg b/themes/pushbutton/logo-active.jpg Binary files differdeleted file mode 100644 index 67e89081c..000000000 --- a/themes/pushbutton/logo-active.jpg +++ /dev/null diff --git a/themes/pushbutton/logo-background.jpg b/themes/pushbutton/logo-background.jpg Binary files differdeleted file mode 100644 index d47005fbb..000000000 --- a/themes/pushbutton/logo-background.jpg +++ /dev/null diff --git a/themes/pushbutton/logo-hover.jpg b/themes/pushbutton/logo-hover.jpg Binary files differdeleted file mode 100644 index 5e662f5df..000000000 --- a/themes/pushbutton/logo-hover.jpg +++ /dev/null diff --git a/themes/pushbutton/logo.png b/themes/pushbutton/logo.png Binary files differdeleted file mode 100644 index 4d0a7e98d..000000000 --- a/themes/pushbutton/logo.png +++ /dev/null diff --git a/themes/pushbutton/screenshot.png b/themes/pushbutton/screenshot.png Binary files differdeleted file mode 100644 index 139e1a7db..000000000 --- a/themes/pushbutton/screenshot.png +++ /dev/null diff --git a/themes/pushbutton/style.css b/themes/pushbutton/style.css deleted file mode 100644 index 22fe38d83..000000000 --- a/themes/pushbutton/style.css +++ /dev/null @@ -1,619 +0,0 @@ -/* $Id$ */ - -/* -** HTML elements -*/ -body { - color: #000; - background-color: #fff; - margin: 0; - padding: 0; -} -body, p, td, li, ul, ol { - font-family: Verdana, Helvetica, Arial, sans-serif; -} -h1, h2, h3, h4, h5, h6 { - font-family: "Trebuchet MS", Geneva, Arial, Helvetica, SunSans-Regular, Verdana, sans-serif; - margin: 0; -} -h1 { - color: #369; - font-size: 1.6em; -} -tr.dark td, tr.light td { - padding: 0.3em; -} -a:link { - text-decoration: none; - font-weight: bold; - color: #ff8c00; -} -a:visited { - text-decoration: none; - font-weight: bold; - color: #c96; -} -a:hover, a:active { - font-weight: bold; - color: #ff4500; - text-decoration: underline; -} -fieldset { - border: 1px solid #ccc; -} -p { - margin: 0 0 1.3em 0; - padding: 0; -} -blockquote { - border-left: 4px solid #69c; - padding: 0 15px 0 15px; - margin: 25px 100px 25px 50px; - color: #696969; - text-align: left; - font-size: 1.2em; - line-height: 1.3em; - font-family: "Trebuchet MS", Geneva, Arial, Helvetica, SunSans-Regular, Verdana, sans-serif; -} -pre { - background-color: #eee; - padding: 0.75em 1.5em; - font-size: 1.2em; - border: 1px solid #ddd; -} -.form-item { - margin-top: 1em; -} -.form-item label { - color: #369; -} -.item-list .title { - color: #369; - font-size: 0.85em; -} - -/* -** Page layout blocks / IDs -*/ -#primary-menu { - border-collapse: separate; - background-color: #e0edfb; - border-bottom: 3px solid #69c; -} -#primary-menu tr { - background: transparent url(header-a.jpg) left bottom repeat; -} -td#home { - background: transparent url(logo-background.jpg) left top repeat; -} -td#home a:link img, td#home a:visited img { - background: transparent url(logo-active.jpg) repeat; - width: 144px; - height: 63px; -} -td#home a:hover img { - background: transparent url(logo-hover.jpg) repeat; - width: 144px; - height: 63px; -} -.primary-links, .primary-links a:link, .primary-links a:visited { - color: #369; -} -.primary-links a:hover { - color: #000; -} -#primary-menu .primary-links { - background: transparent url(header-b.jpg) left top no-repeat; - font-size: 0.79em; -} -#primary-menu .primary-links h1, #primary-menu .primary-links h2, #primary-menu .primary-links h3 { - font-size: 2.3em; - color: #369; -} -#secondary-menu { - border-collapse: separate; - background-color: #369; - border-bottom: 3px solid #69c; -} -.secondary-links, .secondary-links a:link, .secondary-links a:visited { - color: #e4e9eb; -} -.secondary-links a:hover { - color: #fff; - text-decoration: underline; -} -#secondary-menu .secondary-links { - font-size: 0.85em; -} -.tabs { - margin: 15px 0 15px 0; -} -.tabs ul.primary { - border-collapse: collapse; - padding: 0 0 3px 10px; - white-space: nowrap; - list-style: none; - margin: 0 0 0 0; - height: auto; - line-height: normal; - border-bottom: 2px solid #336699; -} -.tabs ul.primary li { - display: inline; -} -.tabs ul.primary li a { - padding: 3px 10px 3px 10px; - background: #fff url(tabs-off.png) left top no-repeat; - border-color: #6699CC; - border-width: 2px; - border-style: none solid none none; - height: auto; - margin-right: 10px; - text-decoration: none; - text-transform: lowercase; -} -.tabs ul.primary li.active a { - background: #336699 url(tabs-on.png) left top no-repeat; - border-right: 2px solid #336699; - color: #fff; -} -.tabs ul.primary li a:hover { - background-color: #fffaf0; - color: #ff4500; -} -.tabs ul.secondary { - border-collapse: collapse; - padding: 10px 0 10px 0px; - margin: 0 0 0 0; - white-space: nowrap; - width: 100%; - list-style: none; - height: auto; - line-height: normal; - border-bottom: none; -} -.tabs ul.secondary li { - display: inline; - height: auto; - padding: 0 0 0 10px; - text-decoration: none; - border-right: none; -} -.tabs ul.secondary li a { - background: #fff url(tabs-option-off.png) left center no-repeat; - padding: 10px 0 10px 25px; - margin: 0 0 0 0; -} -.tabs ul.secondary li a.active { - background: #fff url(tabs-option-on.png) left center no-repeat; - color: #369; - border-bottom: none; -} -.tabs ul.secondary li a:hover { - background: #fff url(tabs-option-hover.png) left center no-repeat; - color: #FF4500 -} -#content { - background-color: #fff; -} -#contentstart { - background-color: #fff; -} -#menu { - padding: 0.5em 0.5em 0 0.5em; - text-align: right; - vertical-align: middle; -} -#search .form-text, #search .form-submit { - border: 1px solid #369; - font-size: 0.85em; -} -#search .form-text { - width: 8em; - height: 1.4em; - padding: 0 0.5em 0 0.5em; - margin: 0 0 0.5em 0; -} -#search .form-submit { - height: 1.5em; -} -#mission { - background-color: #fff; - color: #696969; - border-top: 2px solid #dcdcdc; - border-bottom: 2px solid #dcdcdc; - padding: 10px 10px 10px 10px; - margin: 20px 35px 0px 35px; - font-family: "Trebuchet MS", Geneva, Arial, Helvetica, SunSans-Regular, Verdana, sans-serif; - font-size: 1.1em; - font-weight: normal; -} -#site-info { - background-color: #bdd3ea; - background-image: url('header-c.png'); - font-family: "Trebuchet MS", Geneva, Arial, Helvetica, SunSans-Regular, Verdana, sans-serif; -} -.site-name { - font-size: 1.2em; -} -.site-name a:link, .site-name a:visited { - color: #fff; -} -.site-name a:hover { - color: #ff8c00; - text-decoration: none; -} -.site-slogan { - font-size: 0.8em; - font-weight: bold; -} -#main { - /* padding in px not ex because IE messes up 100% width tables otherwise */ - padding: 30px 35px 50px 35px; - background: transparent url(background.png) center center no-repeat; - /* fix background overlapping text in IE (aka Peekaboo Bug) */ - position: relative; -} -#mission, .node .content, .comment .content { - line-height: 1.4; -} -#help { - font-size: 0.9em; - margin-bottom: 1em; -} -.breadcrumb { - margin-bottom: .5em; -} -.messages { - background-color: #eee; - border: 1px solid #ccc; - padding: 0.3em; - margin-bottom: 1em; -} -.error { - border-color: red; -} -.nav { - padding: 0px 0px 0px 0px; - margin: 0px 0px 0px 0px; -} -#sidebar-left, #sidebar-right { - font-size: 0.75em; - width: 175px; - /* padding in px not ex because IE messes up 100% width tables otherwise */ - padding: 25px 10px 75px 10px; - vertical-align: top; - background: #FFFAF0; -} -#sidebar-left { - border-right: 3px solid #f5f5f5; -} -#sidebar-right { - border-left: 3px solid #f5f5f5; -} -#sidebar-left li, #sidebar-right li { - font-size: 1em; -} -.node .content { - text-align: left; - font-size: 0.85em; - line-height: 1.3; -} -.comment .content { - text-align: left; - font-size: 0.85em; - line-height: 1.3; -} -#footer-message { - padding: 15px 100px 30px 100px; - font-size: 0.85em; - text-align: center; - color: #aaa; -} -table#footer-menu { - border-top: 3px solid #6699cc; - border-bottom: 3px solid #6699cc; - background-color: #369; - color: #e4e9eb; -} -#footer-menu td { - padding: 5px; - font-size: 0.75em; -} -#footer-menu .primary-links, #footer-menu a:link, #footer-menu a:visited { - color: #e4e9eb; -} -#footer-menu a:hover { - color: #fff; - text-decoration: underline; -} -#footer-menu .primary-links h1, #footer-menu .primary-links h2, #footer-menu .primary-links h3 { - font-size: 1.3em; - color: #e4e9eb; -} -/* -** Common declarations for child classes of node, comment, block, box, etc. -** If you want any of them styled differently for a specific parent, add -** additional rules /with only the differing properties!/ to .parent .class. -** See .comment .title for an example. -*/ -#content .title, #content .title a { - color: #369; -} -.content h1 { - color: #369; - font-size: 1.9em; -} -.content h2 { - color: #58b; - font-size: 1.7em; -} -.content h3 { - color: #69c; - font-size: 1.5em; -} -.content h4 { - color: #8be; - font-size: 1.3em; -} -.content h5 { - color: #96c6f6; - font-size: 1.15em; -} -.submitted { - color: #999; - font-size: 0.79em; -} -.links { - color: #ff8c00; - font-size: 0.8em; - padding: 0px 0px 0px 0px; - margin: 0px 0px 0px 0px; -} -.links a { - font-weight: bold; -} -.box { - padding: 0 0 1.5em 0; -} -.box { - padding: 0px 0px 0px 0px; - margin: 0px 0px 0px 0px; -} -.box h2 { - font-size: 9px; -} -.block .title h3 { - border-bottom: 2px solid #6699cc; - color: #369; - font-size: 18px; - font-weight: bold; - padding: 10px 5px 10px 30px; - margin-bottom: .25em; - background: transparent url(icon-block.png) left center no-repeat; -} -.block .content { - padding: 5px 5px 5px 5px; -} -.block { - margin-bottom: 1.5em; -} -.box .title { - font-size: 1.1em; -} -.node { - margin: .5em 0 2.5em 0; -} -.node .content, .comment .content { - margin: .5em 0 .5em 0; -} -.node .taxonomy { - color: #999; - font-size: 0.83em; - padding: 1.5em; -} -.node .picture { - border: 1px solid #fff; - float: right; - margin: 0.5em; -} -.comment { - border: 1px solid #abc; - padding: .5em; - margin-bottom: 1em; -} -.comment .title { - font-size: 1em; - padding: 10px 0px 12px 19px; - background: transparent url(icon-comment.png) left center no-repeat; -} -.comment .new { - font-weight: bold; - font-size: 1em; - margin-left: 2px; - color: red; -} -.comment .picture { - border: 1px solid #fff; - float: right; - margin: 10px; -} -.links { - font-size: 0.75em; -} -.links .prev, .links .next, .links .up { - font-size: 1.15em; -} -.titles .prev, .titles .next { - font-size: 0.85em; - font-weight: bold; - color: #444; -} -.hide { - display: none -} -.nav .links .next a:link { - padding: 17px 17px 17px 0; - background: transparent url(arrow-next.png) right center no-repeat; -} -.nav .links .next a:visited { - padding: 17px 17px 17px 0; - background: transparent url(arrow-next-visited.png) right center no-repeat; -} -.nav .links .next a:hover { - padding: 17px 17px 17px 0; - background: transparent url(arrow-next-hover.png) right center no-repeat; -} -.nav .links .prev a:link { - padding: 17px 0 17px 17px; - background: transparent url(arrow-prev.png) left center no-repeat; -} -.nav .links .prev a:visited { - padding: 17px 0 17px 17px; - background: transparent url(arrow-prev-visited.png) left center no-repeat; -} -.nav .links .prev a:hover { - padding: 17px 0 17px 17px; - background: transparent url(arrow-prev-hover.png) left center no-repeat; -} -.nav .links .up a:link { - padding: 11px 0 17px 0; - background: transparent url(arrow-up.png) center top no-repeat; -} -.nav .links .up a:visited { - padding: 11px 0 17px 0; - background: transparent url(arrow-up-visited.png) center top no-repeat; -} -.nav .links .up a:hover { - padding: 11px 0 17px 0; - background: transparent url(arrow-up-hover.png) center top no-repeat; -} - -/* -** Module specific styles -*/ -.content .active { - color: #369; -} -#aggregator .feed { - background-color: #eee; - border: 1px solid #ccc; - padding: 1em; - margin: 1em 0 1em 0; -} -#aggregator .news-item .source { - color: #999; - font-style: italic; - font-size: 0.85em; -} -#aggregator .title { - font-size: 1em; -} -#aggregator h3 { - margin-top: 1em; -} -#tracker th { - text-align: center; - background-color: #f5f5f5; - border-bottom: 1px solid #ddd; - border-right: 1px solid #ddd; - border-left: 1px solid #fafafa; -} -#tracker th img { - float: right; -} -#tracker tr.light, #tracker tr.dark { - background-color: #fff; -} -#tracker td { - vertical-align: top; - padding: 1em 1em 1em 0; - border-bottom: 1px solid #bbb; -} -#forum { - margin: 15px 0 15px 0; - background-color: #fff; -} -#forum table { - width: 100%; - border: 2px solid #69c; -} -#forum table tr th { - text-align: center; - background: #69c; - color: #fff; - font-size: 0.75em; - border-bottom: 1px solid #aaa; -} -#forum table tr th a { - color: #fff; - text-decoration: underline; -} -#forum table tr th img { - margin: 0; -} -#forum tr.dark { - background: #e0edfb; -} -#forum tr.light { - background: #fff; -} -#forum td { - padding: 0.5em 0.5em 0.5em 0.5em; -} -#forum td.container { - color: #000; - background: #369 url(forum-container.jpg) right top no-repeat; - border: 2px solid #69c; -} -#forum td.container a { - color: #e4e9eb; - padding: 20px 0 20px 35px; - background: transparent url(forum-link.png) left center no-repeat; -} -#forum td.container a:visited { - color: #e4e9eb; -} -#forum td.statistics, #forum td.settings, #forum td.pager { - height: 1.5em; - border: 1px solid #bbb; -} -#forum td .name { - color: #96c; -} -#forum td .links { - padding-top: 0.7em; - font-size: 0.9em; -} -.block-forum h3 { - margin-bottom: .5em; -} -.calendar a { - text-decoration: none; -} -.calendar td, .calendar th { - padding: 0.4em 0; - border-color: #888; -} -.calendar .row-week td a { - padding: 0.4em 0; -} -.calendar .day-today { - background-color: #69c; -} -.calendar .day-today a { - color: #fff; -} -.calendar .day-selected { - background-color: #369; - color: #fff; -} -.calendar .header-week { - background-color: #ccc; -} -.calendar .day-blank { - background-color: #ccc; -} -.calendar .row-week td a:hover { - background-color: #fff; color: #000; -} diff --git a/themes/pushbutton/tabs-off.png b/themes/pushbutton/tabs-off.png Binary files differdeleted file mode 100644 index 5199a9ec8..000000000 --- a/themes/pushbutton/tabs-off.png +++ /dev/null diff --git a/themes/pushbutton/tabs-on.png b/themes/pushbutton/tabs-on.png Binary files differdeleted file mode 100644 index 4f73e50e2..000000000 --- a/themes/pushbutton/tabs-on.png +++ /dev/null diff --git a/themes/pushbutton/tabs-option-hover.png b/themes/pushbutton/tabs-option-hover.png Binary files differdeleted file mode 100644 index 6a77858a3..000000000 --- a/themes/pushbutton/tabs-option-hover.png +++ /dev/null diff --git a/themes/pushbutton/tabs-option-off.png b/themes/pushbutton/tabs-option-off.png Binary files differdeleted file mode 100644 index e3c3a3a0e..000000000 --- a/themes/pushbutton/tabs-option-off.png +++ /dev/null diff --git a/themes/pushbutton/tabs-option-on.png b/themes/pushbutton/tabs-option-on.png Binary files differdeleted file mode 100644 index 93ca79491..000000000 --- a/themes/pushbutton/tabs-option-on.png +++ /dev/null diff --git a/themes/pushbutton/xtemplate.xtmpl b/themes/pushbutton/xtemplate.xtmpl deleted file mode 100644 index ff8be80de..000000000 --- a/themes/pushbutton/xtemplate.xtmpl +++ /dev/null @@ -1,165 +0,0 @@ -<!-- BEGIN: header --><!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> -<html xmlns="http://www.w3.org/1999/xhtml" lang="{language}" xml:lang="{language}"> -<head> - <title>{head_title}</title> - {head} - {styles} - <script type="text/javascript"> </script> -</head> - -<body bgcolor="#ffffff" {onload_attributes}> - -<div class="hide"><a href="#content" title="Skip navigation." accesskey="2">Skip navigation</a>.</div> - -<table id="primary-menu" summary="Navigation elements." border="0" cellpadding="0" cellspacing="0" width="100%"> - <tr> - <td id="home" width="10%"> - - <!-- BEGIN: logo --> - <a href="./" title="Home"><img src="{logo}" alt="Home" width="144" height="63" border="0" /></a> - <!-- END: logo --> - - </td> - - <td id="site-info" width="20%"> - - <!-- BEGIN: site_name --> - <div class='site-name'><a href="./" title="Home">{site_name}</a></div> - <!-- END: site_name --> - - <!-- BEGIN: site_slogan --> - <div class='site-slogan'>{site_slogan}</div> - <!-- END: site_slogan --> - - </td> - - <td class="primary-links" width="70%" align="center" valign="middle"> - - {primary_links} - - </td> - </tr> -</table> - -<table id="secondary-menu" summary="Navigation elements." border="0" cellpadding="0" cellspacing="0" width="100%"> - <tr> - <td class="secondary-links" width="75%" align="center" valign="middle"> - {secondary_links} - </td> - <td width="25%" align="center" valign="middle"> - <!-- BEGIN: search_box --> - <form action="{search_url}" method="post"> - <div id="search"> - <input class="form-text" type="text" size="15" value="" name="edit[keys]" alt="{search_description}" /> - <input class="form-submit" type="submit" value="{search_button_text}" alt="submit" /> - </div> - </form> - <!-- END: search_box --> - </td> - </tr> -</table> - -<table id="content" border="0" cellpadding="15" cellspacing="0" width="100%"> - <tr> - <!-- BEGIN: blocks --> - <td id="sidebar-left"> - {blocks} - </td> - <!-- END: blocks --> - <td valign="top"> - <!-- BEGIN: mission --> - <div id="mission">{mission}</div> - <!-- END: mission --> - <div id="main"> - <!-- BEGIN: title --> - {breadcrumb} - <h1 class="title">{title}</h1> - <!-- BEGIN: tabs --> - <div class="tabs">{tabs}</div> - <!-- END: tabs --> - - <!-- END: title --> - <!-- BEGIN: help --> - {help} - <!-- END: help --> - <!-- BEGIN: message --> - {message} - <!-- END: message --> -<!-- END: header --> - -<!-- BEGIN: node --> - <div class="node {sticky}"> - <!-- BEGIN: picture --> - {picture} - <!-- END: picture --> - <!-- BEGIN: title --> - <h1 class="title"><a href="{link}">{title}</a></h1> - <!-- END: title --> - <span class="submitted">{submitted}</span> - <!-- BEGIN: taxonomy --> - <span class="taxonomy">{taxonomy}</span> - <!-- END: taxonomy --> - <div class="content">{content}</div> - <!-- BEGIN: links --> - <div class="links">» {links}</div> - <!-- END: links --> - </div> -<!-- END: node --> - -<!-- BEGIN: comment --> - <div class="comment"> - <!-- BEGIN: picture --> - {picture} - <!-- END: picture --> - <h3 class="title">{title}</h3> - <div class="submitted">{submitted}<!-- BEGIN: new --><span class="new"> *{new}</span><!-- END: new --></div> - <div class="content">{content}</div> - <!-- BEGIN: links --> - <div class="links">» {links}</div> - <!-- END: links --> - </div> -<!-- END: comment --> - -<!-- BEGIN: box --> - <div class="box"> - <h2 class="title">{title}</h2> - <div class="content">{content}</div> - </div> -<!-- END: box --> - -<!-- BEGIN: block --> - <div class="block block-{module}" id="block-{module}-{delta}"> - <div class="title"><h3>{title}</h3></div> - <div class="content">{content}</div> - </div> -<!-- END: block --> - -<!-- BEGIN: footer --> - </div><!-- main --> - </td> - <!-- BEGIN: blocks --> - <td id="sidebar-right"> - {blocks} - </td> - <!-- END: blocks --> - </tr> -</table> - -<table id="footer-menu" summary="Navigation elements." border="0" cellpadding="0" cellspacing="0" width="100%"> - <tr> - <td align="center" valign="middle"> - <div class="primary-links">{primary_links}</div> - <div class="secondary-links">{secondary_links}</div> - </td> - </tr> -</table> - -<!-- BEGIN: message --> -<div id="footer-message"> - {footer_message} -</div> -<!-- END: message --> -{footer} -</body> -</html> -<!-- END: footer --> |