*/ $mesg = ''; $object = new Logement($db); if ($id > 0 || !empty($ref)) { $result = $object->fetch($id, $ref); $dir = !empty($conf->gestimmo->multidir_output[$object->entity]) ? $conf->gestimmo->multidir_output[$object->entity] : $conf->gestimmo->multidir_output[$object->entity]; //$dir = "/var/www/dev/immodol/documents/biens"; dol_syslog("dans PHOTO 2 " . $dir . "id=" . $id . "ref " . $ref); } /* * Actions */ if (isset($_FILES['userfile']) && $_FILES['userfile']['size'] > 0 && GETPOST('sendit') && !empty($conf->global->MAIN_UPLOAD_DOC)) { dol_syslog("Product Create " . $dir); if ($object->id) { $result = $object->add_photo($dir, $_FILES['userfile']); } } if ($action == 'confirm_delete' && $_GET["file"] && $confirm == 'yes' && ($user->rights->produit->creer || $user->rights->service->creer)) { $object->delete_photo($dir . "/" . $_GET["file"]); } if ($action == 'addthumb' && $_GET["file"]) { $object->add_thumb($dir . "/" . $_GET["file"]); } /* * View */ $form = new Form($db); if ($object->id) { llxHeader("", "", $langs->trans("biens" . $object->ref)); /*