Fix: more compatible with alternative path

Fix: uniformize code
This commit is contained in:
Regis Houssin
2010-12-19 11:05:07 +00:00
parent 749b9c333e
commit 17df30b7fa
19 changed files with 142 additions and 112 deletions

View File

@@ -97,7 +97,7 @@ function user_prepare_head($object)
{
$values=explode(':',$value);
if ($values[2]) $langs->load($values[2]);
$head[$h][0] = DOL_URL_ROOT . preg_replace('/__ID__/i',$object->id,$values[3]);
$head[$h][0] = dol_file_exists(preg_replace('/__ID__/i',$object->id,$values[3]),1);
$head[$h][1] = $langs->trans($values[1]);
$head[$h][2] = 'tab'.$values[1];
$h++;
@@ -153,7 +153,7 @@ function group_prepare_head($object)
{
$values=explode(':',$value);
if ($values[2]) $langs->load($values[2]);
$head[$h][0] = DOL_URL_ROOT . preg_replace('/__ID__/i',$object->id,$values[3]);
$head[$h][0] = dol_file_exists(preg_replace('/__ID__/i',$object->id,$values[3]),1);
$head[$h][1] = $langs->trans($values[1]);
$head[$h][2] = 'tab'.$values[1];
$h++;