diff --git a/htdocs/main.inc.php b/htdocs/main.inc.php index 28ca73f005f..d24145ab561 100644 --- a/htdocs/main.inc.php +++ b/htdocs/main.inc.php @@ -26,7 +26,7 @@ * \file htdocs/main.inc.php * \ingroup core * \brief File that defines environment for Dolibarr pages only (variables not required by scripts) - * \version $Id: main.inc.php,v 1.771 2011/08/22 17:47:28 hregis Exp $ + * \version $Id: main.inc.php,v 1.772 2011/08/22 22:26:57 eldy Exp $ */ @ini_set('memory_limit', '64M'); // This may be useless if memory is hard limited by your PHP @@ -755,11 +755,11 @@ if (!empty($conf->global->MAIN_MODULE_MULTICOMPANY)) if (GETPOST('action') == 'switchentity') { $res = @dol_include_once("/multicompany/class/actions_multicompany.class.php"); - + if ($res) { $mc = new ActionsMulticompany($db); - + if($mc->switchEntity(GETPOST('entity')) >= 0) { Header("Location: ".DOL_URL_ROOT.'/'); @@ -1536,6 +1536,7 @@ function getHelpParamFor($helppagename,$langs) /** * Show a search area + * * @param urlaction Url post * @param urlobject Url of the link under the search box * @param title Title search area @@ -1544,7 +1545,8 @@ function getHelpParamFor($helppagename,$langs) */ function printSearchForm($urlaction,$urlobject,$title,$htmlmodesearch='search',$htmlinputname) { - global $langs; + global $conf,$langs; + $ret=''; $ret.='