implement Smarty3

This commit is contained in:
Zach Prezkuta
2013-01-06 14:42:51 -07:00
parent 61b8ea9e1a
commit a0d19ffb72
250 changed files with 6959 additions and 282 deletions

View File

@@ -96,13 +96,6 @@ if((x($_GET,'zid')) && (! $install)) {
if((x($_SESSION,'authenticated')) || (x($_POST,'auth-params')) || ($a->module === 'login'))
require("auth.php");
/*
* Create the page head after setting the language
* and getting any auth credentials
*/
$a->init_pagehead();
if(! x($_SESSION,'sysmsg'))
$_SESSION['sysmsg'] = array();
@@ -280,18 +273,28 @@ if($a->module_loaded) {
if(! $a->error) {
// If a theme has defined an _aside() function, run that first
//
// If the theme function doesn't exist, see if this theme extends another,
// and see if that other theme has an _aside() function--if it does, run it
//
// If $aside_default is not False after the theme _aside() function, run the
// module's _aside() function too
//
// This gives themes more control over how the left sidebar looks
$aside_default = true;
call_hooks($a->module . '_mod_aside',$placeholder);
if(function_exists(str_replace('-','_',current_theme()) . '_' . $a->module . '_aside')) {
$func = str_replace('-','_',current_theme()) . '_' . $a->module . '_aside';
$aside_default = $func($a);
}
elseif(x($a->theme_info,"extends") && $aside_default
elseif($aside_default && x($a->theme_info,"extends")
&& (function_exists(str_replace('-','_',$a->theme_info["extends"]) . '_' . $a->module . '_aside'))) {
$func = str_replace('-','_',$a->theme_info["extends"]) . '_' . $a->module . '_aside';
$aside_default = $func($a);
}
elseif(function_exists($a->module . '_aside') && $aside_default) {
if($aside_default && function_exists($a->module . '_aside')) {
$func = $a->module . '_aside';
$func($a);
}
@@ -329,7 +332,6 @@ if(stristr( implode("",$_SESSION['sysmsg']), t('Permission denied'))) {
call_hooks('page_end', $a->page['content']);
construct_page($a);
session_write_close();