diff --git a/htdocs/main.inc.php b/htdocs/main.inc.php index e1cb471b58d2f..c24f9fc20360d 100644 --- a/htdocs/main.inc.php +++ b/htdocs/main.inc.php @@ -447,9 +447,9 @@ function analyse_sql_and_script(&$var, $type) $dol_authmode=$conf->authmode; // This properties is defined only when logged, to say what mode was successfully used $dol_tz=$_POST["tz"]; $dol_tz_string=$_POST["tz_string"]; - $dol_tz_string=preg_replace('\s*\(.+\)$','',$dol_tz_string); - $dol_tz_string=preg_replace(',','/',$dol_tz_string); - $dol_tz_string=preg_replace('\s','_',$dol_tz_string); + $dol_tz_string=preg_replace('/\s*\(.+\)$/','',$dol_tz_string); + $dol_tz_string=preg_replace('/,/' ,'/',$dol_tz_string); + $dol_tz_string=preg_replace('/\s/','_',$dol_tz_string); $dol_dst=0; if (isset($_POST["dst_first"]) && isset($_POST["dst_second"])) {