From ba091af9472d99b7b5cce08969211310d203d656 Mon Sep 17 00:00:00 2001 From: Regis Houssin Date: Sun, 27 Dec 2009 05:50:46 +0000 Subject: [PATCH] Test: smarty integration and iphone template --- htdocs/main.inc.php | 10 +++++++++- htdocs/master.inc.php | 3 ++- 2 files changed, 11 insertions(+), 2 deletions(-) diff --git a/htdocs/main.inc.php b/htdocs/main.inc.php index 328f9edce49..b6864e8d4e5 100644 --- a/htdocs/main.inc.php +++ b/htdocs/main.inc.php @@ -354,7 +354,15 @@ if (! isset($_SESSION["dol_login"])) { // We show login page include_once(DOL_DOCUMENT_ROOT."/lib/security.lib.php"); - dol_loginfunction($langs,$conf,$mysoc); + // TODO activer smarty par defaut ? + if ($conf->global->MAIN_SMARTY) + { + dol_loginfunction2($langs,$conf,$mysoc); + } + else + { + dol_loginfunction($langs,$conf,$mysoc); + } exit; } diff --git a/htdocs/master.inc.php b/htdocs/master.inc.php index 1dd1f333205..e702c2a32c6 100644 --- a/htdocs/master.inc.php +++ b/htdocs/master.inc.php @@ -418,7 +418,8 @@ if (! defined('MAGPIE_CACHE_DIR')) { define('MAGPIE_CACHE_DIR', $conf->exte if (! defined('MAIN_LABEL_MENTION_NPR') ) define('MAIN_LABEL_MENTION_NPR','NPR'); // If there is at least one module using Smarty -if (sizeof($conf->need_smarty) > 0) +// TODO activer smarty par defaut ? +if (sizeof($conf->need_smarty) > 0 || $conf->global->MAIN_SMARTY) { // Usage of constats in conf.php file is no more required. if (empty($dolibarr_smarty_libs_dir)) $dolibarr_smarty_libs_dir=DOL_DOCUMENT_ROOT.'/includes/smarty/libs/';