Fix: prof id can reach 32 chars

This commit is contained in:
Laurent Destailleur 2012-02-25 01:33:09 +01:00
parent 72ca840cab
commit 85c56d29a6

View File

@ -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 = '<input type="text" name="'.$htmlname.'" size="'.($formlength+1).'" maxlength="'.$formlength.'" value="'.$selected.'">';
$maxlength=$formlength;
if (empty($formlength)) { $formlength=24; $maxlength=32; }
$out = '<input type="text" name="'.$htmlname.'" size="'.($formlength+1).'" maxlength="'.$maxlength.'" value="'.$selected.'">';
return $out;
}