diff --git a/htdocs/admin/modules.php b/htdocs/admin/modules.php index a1f1d0724c6..bc3c0d53760 100644 --- a/htdocs/admin/modules.php +++ b/htdocs/admin/modules.php @@ -250,9 +250,10 @@ if (! empty($categ[$categidx])) if ($conf->global->MAIN_FEATURES_LEVEL >= 1) { + $form = new Form($db); $categidx='expdev'; - $head[$h][0] = DOL_URL_ROOT."/admin/modules.php?mode=".$categidx; - $head[$h][1] = $langs->trans("ModuleFamilyExperimental"); + $head[$h][0] = DOL_URL_ROOT."/admin/modules.php?mode=".$categidx; + $head[$h][1] = $form->textwithpicto($langs->trans("ModuleFamilyExperimental"), $langs->trans('DoNotUseInProduction'), 1, 'warning', '', 0, 3); $head[$h][2] = 'expdev'; $h++; } diff --git a/htdocs/core/class/html.form.class.php b/htdocs/core/class/html.form.class.php index c6ec1d5d151..ed1193e696e 100644 --- a/htdocs/core/class/html.form.class.php +++ b/htdocs/core/class/html.form.class.php @@ -370,28 +370,11 @@ class Form else $paramfortooltiptd =($extracss?' class="'.$extracss.'"':''); // Attribut to put on td text tag $s=""; - if (empty($notabs)) $s.=''; - if ($direction > 0) - { - if ($text != '') - { - $s.=''.$text; - if ($direction) $s.=' '; - $s.=''; - } - if ($direction) $s.=''.$img.''; - } - else - { - if ($direction) $s.=''.$img.''; - if ($text != '') - { - $s.='<'.$tag.$paramfortooltiptd.'>'; - if ($direction) $s.=' '; - $s.=$text.''; - } - } - if (empty($notabs)) $s.='
'; + if (empty($notabs)) $s.=''; + if ($direction < 0) $s.='<'.$tag.$paramfortooltipimg.' valign="top" width="14">'.$img.' '; + if ($text != '') $s.='<'.$tag.$paramfortooltiptd.'>'.$text.''; + if ($direction > 0) $s.='<'.$tag.$paramfortooltipimg.' valign="top" width="14"> '.$img.''; + if (empty($notabs)) $s.='
'; return $s; } @@ -405,9 +388,10 @@ class Form * @param string $type Type of picto (info, help, warning, superadmin...) * @param string $extracss Add a CSS style to td tags * @param int $noencodehtmltext Do not encode into html entity the htmltext + * @param int $notabs 0=Include table and tr tags, 1=Do not include table and tr tags, 2=use div, 3=use span * @return string HTML code of text, picto, tooltip */ - function textwithpicto($text, $htmltext, $direction = 1, $type = 'help', $extracss = '', $noencodehtmltext = 0) + function textwithpicto($text, $htmltext, $direction = 1, $type = 'help', $extracss = '', $noencodehtmltext = 0, $notabs = 0) { global $conf; @@ -439,7 +423,7 @@ class Form elseif ($type == 'admin') $img = img_picto($alt, 'star'); elseif ($type == 'warning') $img = img_warning($alt); - return $this->textwithtooltip($text, $htmltext, 2, $direction, $img, $extracss, 0, '', $noencodehtmltext); + return $this->textwithtooltip($text, $htmltext, 2, $direction, $img, $extracss, $notabs, '', $noencodehtmltext); } /** diff --git a/htdocs/langs/en_US/admin.lang b/htdocs/langs/en_US/admin.lang index fd1549aebfd..74f7ca3b7d9 100644 --- a/htdocs/langs/en_US/admin.lang +++ b/htdocs/langs/en_US/admin.lang @@ -262,6 +262,7 @@ ModuleFamilyFinancial=Financial Modules (Accounting/Treasury) ModuleFamilyECM=Electronic Content Management (ECM) MenuHandlers=Menu handlers MenuAdmin=Menu editor +DoNotUseInProduction=Do not use in production ThisIsProcessToFollow=This is setup to process: StepNb=Step %s FindPackageFromWebSite=Find a package that provides feature you want (for example on official web site %s). diff --git a/htdocs/langs/fr_FR/admin.lang b/htdocs/langs/fr_FR/admin.lang index f885285f23f..ad7f9b2a7b6 100644 --- a/htdocs/langs/fr_FR/admin.lang +++ b/htdocs/langs/fr_FR/admin.lang @@ -257,11 +257,12 @@ ModuleFamilyHr= Ressources humaines ModuleFamilyProjects= Projets/Travail collaboratif ModuleFamilyOther= Autre ModuleFamilyTechnic= Outils multi-modules -ModuleFamilyExperimental= Modules expérimentaux (ne pas utiliser en production) +ModuleFamilyExperimental= Modules expérimentaux ModuleFamilyFinancial= Modules financiers (Compta/trésorerie) ModuleFamilyECM= Gestion Électronique de Documents (GED) MenuHandlers= Gestionnaires menu MenuAdmin= Edition menu +DoNotUseInProduction=Ne pas utiliser en production ThisIsProcessToFollow= Voici la procédure à suivre: StepNb= Etape %s FindPackageFromWebSite=Recherche le package qui répond à votre besoin (par exemple sur le site web %s).