diff --git a/htdocs/core/db/pgsql.class.php b/htdocs/core/db/pgsql.class.php index 41bd45bebff..048ef2d450d 100644 --- a/htdocs/core/db/pgsql.class.php +++ b/htdocs/core/db/pgsql.class.php @@ -410,6 +410,7 @@ class DoliDBPgsql extends DoliDB $this->database_name = $name; pg_set_error_verbosity($this->db, PGSQL_ERRORS_VERBOSE); // Set verbosity to max } + pg_query($this->db, "set datestyle = 'ISO, YMD';"); return $this->db; } diff --git a/htdocs/societe/checkvat/checkVatPopup.php b/htdocs/societe/checkvat/checkVatPopup.php index 9252a479403..13d669789e7 100644 --- a/htdocs/societe/checkvat/checkVatPopup.php +++ b/htdocs/societe/checkvat/checkVatPopup.php @@ -49,8 +49,10 @@ if (! $_REQUEST["vatNumber"]) } else { + $_REQUEST["vatNumber"] = preg_replace('/\^\w/', '', $_REQUEST["vatNumber"]); $countryCode=substr($_REQUEST["vatNumber"],0,2); $vatNumber=substr($_REQUEST["vatNumber"],2); + print ''.$langs->trans("Country").': '.$countryCode.'
'; print ''.$langs->trans("VATIntraShort").': '.$vatNumber.'
'; print '
';