function test_global($glob) { $glob = ctr_global($glob); return $glob; }
} // Initialisation Smarty include_once $thisSite->DOS_BASE_LIB . "Smarty/libs/" . "Smarty.class.php"; $smarty = new Smarty(); $smarty->setTemplateDir($racine_smarty . "smarty/templates/"); $smarty->setCompileDir($racine_smarty . "smarty/templates_c/"); $smarty->setCacheDir($racine_smarty . "smarty/cache/"); $smarty->caching = $thisSite->SMARTY_CACHING; $smarty->cache_lifetime = $thisSite->CACHE_LIFETIME; $smarty->compile_check = FALSE; $smarty->force_compile = TRUE; $smarty->debugging = FALSE; $smarty->error_reporting = E_ALL & ~E_NOTICE; $smarty->muteExpectedErrors(); // // Traitement des GET et POST $__GET = array(); $__POST = array(); if (isset($_GET)) { foreach ($_GET as $k => $v) { $__GET[$k] = ctr_global($v, "strip_tags"); } } if (isset($_POST)) { foreach ($_POST as $k => $v) { $__POST[$k] = ctr_global($v); } } $smarty->assign("__GET", $__GET); $smarty->assign("__POST", $__POST); ///////////////////////////////////////////////////////////////////////////////