diff --git a/htdocs/lib/functions.lib.php b/htdocs/lib/functions.lib.php
index 7a8445e363c..aa7c13e9156 100644
--- a/htdocs/lib/functions.lib.php
+++ b/htdocs/lib/functions.lib.php
@@ -1063,22 +1063,25 @@ function dol_trunc($string,$size=40,$trunc='right',$stringencoding='UTF-8')
/**
- * \brief Show a picto according to module/object (generic function)
- * \param alt Text of alt on image
- * \param object Objet pour lequel il faut afficher le logo (example: user, group, action, bill, contract, propal, product, ...)
+ * Show a picto according to module/object (generic function)
+ * @param alt Text of alt on image
+ * @param object Objet pour lequel il faut afficher le logo (example: user, group, action, bill, contract, propal, product, ...)
* Pour les modules externe utiliser nomimage@mymodule pour rechercher dans le repertoire "img" du module
+ * @param cssclass Define a specific css class
* \return string Retourne tag img
*/
-function img_object($alt, $object)
+function img_object($alt, $object, $cssclass='')
{
global $conf,$langs;
+
+ $cssclass = (!empty($cssclass)?'class="'.$cssclass.'"':'');
if (preg_match('/^([^@]+)@([^@]+)$/i',$object,$regs))
{
- return '
';
+ return '
';
}
- return '
';
+ return '
';
}
/**
diff --git a/htdocs/main.inc.php b/htdocs/main.inc.php
index 573af8fb50c..84d806cb975 100644
--- a/htdocs/main.inc.php
+++ b/htdocs/main.inc.php
@@ -968,10 +968,11 @@ function top_menu($head, $title='', $target='', $disablejs=0, $disablehead=0, $a
$res=@include_once(DOL_DOCUMENT_ROOT.'/multicompany/class/actions_multicompany.class.php');
if ($res)
{
- $mc = new ActionsMulticompany($db);
-
- $select_entity = '