From 85c56d29a6def675e7ec03b30fe03a2dbfdb806b Mon Sep 17 00:00:00 2001 From: Laurent Destailleur Date: Sat, 25 Feb 2012 01:33:09 +0100 Subject: [PATCH] Fix: prof id can reach 32 chars --- htdocs/core/class/html.formcompany.class.php | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/htdocs/core/class/html.formcompany.class.php b/htdocs/core/class/html.formcompany.class.php index 2b5ba7e282d..5a4d19f93c9 100644 --- a/htdocs/core/class/html.formcompany.class.php +++ b/htdocs/core/class/html.formcompany.class.php @@ -654,7 +654,7 @@ class FormCompany { global $conf,$langs; - $formlength=24; + $formlength=0; if ($country_code == 'FR' && empty($conf->global->MAIN_DISABLEPROFIDRULES)) { if ($idprof==1) $formlength=9; @@ -676,7 +676,10 @@ class FormCompany if (! $selected && $idprof==3) $selected=$this->ape; if (! $selected && $idprof==4) $selected=$this->idprof4; - $out = ''; + $maxlength=$formlength; + if (empty($formlength)) { $formlength=24; $maxlength=32; } + + $out = ''; return $out; }