diff --git a/htdocs/core/class/translate.class.php b/htdocs/core/class/translate.class.php index 905ccf9349b..2e7db582b5f 100644 --- a/htdocs/core/class/translate.class.php +++ b/htdocs/core/class/translate.class.php @@ -699,7 +699,7 @@ class Translate $str ); - $str = preg_replace('/%\)/', '__percent__)', $str); + $str = preg_replace('/%\)/', '__percent_parentesis__', $str); if (strpos($key, 'Format') !== 0) { try { @@ -710,7 +710,7 @@ class Translate } } - $str = str_replace('__percent__', '%', $str); + $str = str_replace('__percent_parentesis__', '%)', $str); // Encode string into HTML $str = htmlentities($str, ENT_COMPAT, $this->charset_output); // Do not convert simple quotes in translation (strings in html are embraced by "). Use dol_escape_htmltag around text in HTML content