diff --git a/htdocs/core/lib/emaillayout.lib.php b/htdocs/core/lib/emaillayout.lib.php index 3859898a02d..53753e46a45 100644 --- a/htdocs/core/lib/emaillayout.lib.php +++ b/htdocs/core/lib/emaillayout.lib.php @@ -33,7 +33,7 @@ function getHtmlOfLayout($name) global $conf, $mysoc, $user, $langs; $substitutionarray = array(); - $substitutionarray = getCommonSubstitutionArray($langs, $substitutionarray); + $substitutionarray = getCommonSubstitutionArray($langs, 1); // TODO Read template from a file "install/doctemplates/maillayout/xxx.html" diff --git a/htdocs/main.inc.php b/htdocs/main.inc.php index e95f4d013f5..24774489d58 100644 --- a/htdocs/main.inc.php +++ b/htdocs/main.inc.php @@ -280,7 +280,7 @@ function analyseVarsForSqlAndScriptsInjection(&$var, $type, $stopcode = 1) //$errormessage .= ' paramkey='.htmlentities($key, ENT_COMPAT, 'UTF-8'); // Disabled to avoid text injection $errormessage2 = 'page='.htmlentities((empty($_SERVER["REQUEST_URI"]) ? '' : $_SERVER["REQUEST_URI"]), ENT_COMPAT, 'UTF-8'); - $errormessage2 .= ' paramtype='.htmlentities($type, ENT_COMPAT, 'UTF-8'); + $errormessage2 .= ' paramtype='.htmlentities((string) $type, ENT_COMPAT, 'UTF-8'); $errormessage2 .= ' paramkey='.htmlentities($key, ENT_COMPAT, 'UTF-8'); $errormessage2 .= ' paramvalue='.htmlentities($value, ENT_COMPAT, 'UTF-8');