30 require
'../main.inc.php';
31 require_once DOL_DOCUMENT_ROOT.
'/core/lib/usergroups.lib.php';
32 require_once DOL_DOCUMENT_ROOT.
'/core/lib/admin.lib.php';
33 require_once DOL_DOCUMENT_ROOT.
'/core/lib/images.lib.php';
34 require_once DOL_DOCUMENT_ROOT.
'/core/lib/files.lib.php';
35 require_once DOL_DOCUMENT_ROOT.
'/core/lib/functions2.lib.php';
36 require_once DOL_DOCUMENT_ROOT.
'/core/class/html.formother.class.php';
37 require_once DOL_DOCUMENT_ROOT.
'/core/class/html.formadmin.class.php';
40 $langs->loadLangs(array(
'admin',
'languages',
'other',
'companies',
'products',
'members',
'projects',
'hrm',
'agenda'));
46 $action =
GETPOST(
'action',
'aZ09');
47 $contextpage =
GETPOST(
'contextpage',
'aZ') ?
GETPOST(
'contextpage',
'aZ') :
'adminihm';
49 $mode =
GETPOST(
'mode',
'aZ09') ?
GETPOST(
'mode',
'aZ09') :
'other';
51 if (!defined(
"MAIN_MOTD")) {
52 define(
"MAIN_MOTD",
"");
59 $parameters = array();
60 $reshook = $hookmanager->executeHooks(
'doActions', $parameters, $object, $action);
65 if (
GETPOST(
'cancel',
'alpha')) {
71 if (preg_match(
'/^(set|del)_([A-Z_]+)$/', $action, $regs)) {
72 if ($regs[1] ==
'set') {
79 if ($action ==
'removebackgroundlogin' && !empty($conf->global->MAIN_LOGIN_BACKGROUND)) {
81 require_once DOL_DOCUMENT_ROOT.
'/core/lib/files.lib.php';
83 $logofile = $conf->mycompany->dir_output.
'/logos/'.$conf->global->MAIN_LOGIN_BACKGROUND;
99 if ($action ==
'update') {
102 if ($mode ==
'template') {
109 $val =
GETPOST(
'THEME_DARKMODEENABLED');
114 dolibarr_set_const($db,
"THEME_DARKMODEENABLED", $val,
'chaine', 0,
'', $conf->entity);
119 $val=
GETPOST(
'THEME_TOPMENU_DISABLE_IMAGE');
123 dolibarr_set_const($db,
'THEME_TOPMENU_DISABLE_IMAGE',
GETPOST(
'THEME_TOPMENU_DISABLE_IMAGE'),
'chaine', 0,
'', $conf->entity);
138 dolibarr_set_const($db,
'THEME_ELDY_TOPMENU_BACK1', $val,
'chaine', 0,
'', $conf->entity);
145 dolibarr_set_const($db,
'THEME_ELDY_VERMENU_BACK1', $val,
'chaine', 0,
'', $conf->entity);
152 dolibarr_set_const($db,
'THEME_ELDY_TEXTTITLENOTAB', $val,
'chaine', 0,
'', $conf->entity);
159 dolibarr_set_const($db,
'THEME_ELDY_BACKTITLE1', $val,
'chaine', 0,
'', $conf->entity);
166 dolibarr_set_const($db,
'THEME_ELDY_TEXTTITLE', $val,
'chaine', 0,
'', $conf->entity);
173 dolibarr_set_const($db,
'THEME_ELDY_TEXTTITLELINK', $val,
'chaine', 0,
'', $conf->entity);
180 dolibarr_set_const($db,
'THEME_ELDY_LINEIMPAIR1', $val,
'chaine', 0,
'', $conf->entity);
186 dolibarr_set_const($db,
'THEME_ELDY_LINEIMPAIR2', $val,
'chaine', 0,
'', $conf->entity);
193 dolibarr_set_const($db,
'THEME_ELDY_LINEPAIR1', $val,
'chaine', 0,
'', $conf->entity);
199 dolibarr_set_const($db,
'THEME_ELDY_LINEPAIR2', $val,
'chaine', 0,
'', $conf->entity);
213 dolibarr_set_const($db,
"THEME_ELDY_USE_HOVER", $val,
'chaine', 0,
'', $conf->entity);
220 dolibarr_set_const($db,
"THEME_ELDY_USE_CHECKED", $val,
'chaine', 0,
'', $conf->entity);
227 dolibarr_set_const($db,
'THEME_ELDY_BTNACTION', $val,
'chaine', 0,
'', $conf->entity);
234 dolibarr_set_const($db,
'THEME_ELDY_TEXTBTNACTION', $val,
'chaine', 0,
'', $conf->entity);
238 if ($mode ==
'dashboard') {
242 if ($mode ==
'other') {
246 dolibarr_set_const($db,
"MAIN_SIZE_LISTE_LIMIT",
GETPOST(
"main_size_liste_limit",
'int'),
'chaine', 0,
'', $conf->entity);
247 dolibarr_set_const($db,
"MAIN_SIZE_SHORTLIST_LIMIT",
GETPOST(
"main_size_shortliste_limit",
'int'),
'chaine', 0,
'', $conf->entity);
254 dolibarr_set_const($db,
"MAIN_DEFAULT_WORKING_DAYS",
GETPOST(
"MAIN_DEFAULT_WORKING_DAYS",
'alphanohtml'),
'chaine', 0,
'', $conf->entity);
255 dolibarr_set_const($db,
"MAIN_DEFAULT_WORKING_HOURS",
GETPOST(
"MAIN_DEFAULT_WORKING_HOURS",
'alphanohtml'),
'chaine', 0,
'', $conf->entity);
257 dolibarr_set_const($db,
"MAIN_BUGTRACK_ENABLELINK",
GETPOST(
"MAIN_BUGTRACK_ENABLELINK",
'alpha'),
'chaine', 0,
'', $conf->entity);
259 dolibarr_set_const($db,
"MAIN_FIRSTNAME_NAME_POSITION",
GETPOST(
"MAIN_FIRSTNAME_NAME_POSITION",
'aZ09'),
'chaine', 0,
'', $conf->entity);
262 if ($mode ==
'login') {
266 $varforimage =
'imagebackground';
267 $dirforimage = $conf->mycompany->dir_output .
'/logos/';
268 if ($_FILES[$varforimage][
"tmp_name"]) {
270 if (preg_match(
'/([^\\/:]+)$/i', $_FILES[$varforimage][
"name"], $reg)) {
271 $original_file = $reg[1];
275 dol_syslog(
"Move file " . $_FILES[$varforimage][
"tmp_name"] .
" to " . $dirforimage . $original_file);
276 if (!is_dir($dirforimage)) {
279 $result =
dol_move_uploaded_file($_FILES[$varforimage][
"tmp_name"], $dirforimage . $original_file, 1, 0, $_FILES[$varforimage][
'error']);
281 dolibarr_set_const($db,
"MAIN_LOGIN_BACKGROUND", $original_file,
'chaine', 0,
'', $conf->entity);
282 } elseif (preg_match(
'/^ErrorFileIsInfectedWithAVirus/', $result)) {
284 $langs->load(
"errors");
285 $tmparray = explode(
':', $result);
286 setEventMessages($langs->trans(
'ErrorFileIsInfectedWithAVirus', $tmparray[1]),
null,
'errors');
293 $langs->load(
"errors");
300 $_SESSION[
"mainmenu"] =
"";
302 if (
GETPOST(
'dol_resetcache')) {
303 dolibarr_set_const($db,
"MAIN_IHM_PARAMS_REV", ((
int) $conf->global->MAIN_IHM_PARAMS_REV) + 1,
'chaine', 0,
'', $conf->entity);
306 header(
"Location: ".$_SERVER[
"PHP_SELF"].
"?mainmenu=home&leftmenu=setup".
'&mode='.$mode.(GETPOSTISSET(
'page_y') ?
'&page_y='.GETPOST(
'page_y',
'int') :
''));
315 $wikihelp =
'EN:First_setup|FR:Premiers_paramétrages|ES:Primeras_configuraciones';
324 print
'<span class="opacitymedium">'.$langs->trans(
"DisplayDesc").
"</span><br>\n";
328 require_once DOL_DOCUMENT_ROOT.
'/core/class/doleditor.class.php';
330 print
'<form enctype="multipart/form-data" method="POST" action="'.$_SERVER[
"PHP_SELF"].
'">';
331 print
'<input type="hidden" name="token" value="'.newToken().
'">';
332 print
'<input type="hidden" name="action" value="update">';
333 print
'<input type="hidden" name="page_y" value="">';
334 print
'<input type="hidden" id="mode" name="mode" value="'.dol_escape_htmltag($mode).
'">';
335 print
'<input type="hidden" name="dol_resetcache" value="1">';
345 if ($mode ==
'other') {
346 print
'<div class="div-table-responsive-no-min">';
347 print
'<table summary="edit" class="noborder centpercent editmode tableforfield">';
349 print
'<tr class="liste_titre"><td class="titlefieldmiddle">';
350 print $langs->trans(
"Language");
351 print
'</td><td class="titlefieldmiddle">';
355 print
'<tr class="oddeven"><td>'.$langs->trans(
"DefaultLanguage").
'</td><td>';
356 print
img_picto(
'',
'language',
'class="pictofixedwidth"');
357 print $formadmin->select_language($conf->global->MAIN_LANG_DEFAULT,
'MAIN_LANG_DEFAULT', 1,
null,
'', 0, 0,
'minwidth300', 2);
363 print
'<tr class="oddeven"><td>' . $langs->trans(
"EnableMultilangInterface") .
'</td><td>';
364 print
ajax_constantonoff(
"MAIN_MULTILANGS", array(), $conf->entity, 0, 0, 1, 0, 0, 0,
'',
'language');
368 print
'</table>' .
"\n";
371 print
'<div class="center">';
372 print
'<input class="button button-save reposition" type="submit" name="submit" value="' . $langs->trans(
"Save") .
'">';
373 print
'<input class="button button-cancel reposition" type="submit" name="cancel" value="' . $langs->trans(
"Cancel") .
'">';
380 print
'<div class="div-table-responsive-no-min">';
381 print
'<table summary="otherparameters" class="noborder centpercent editmode tableforfield">';
383 print
'<tr class="liste_titre"><td class="titlefieldmiddle">';
384 print $langs->trans(
"Miscellaneous");
386 print
'<td class="titlefieldmiddle"></td>';
390 print
'<tr class="oddeven"><td>' . $langs->trans(
"ShowQuickAddLink") .
'</td><td>';
391 print
ajax_constantonoff(
"MAIN_USE_TOP_MENU_QUICKADD_DROPDOWN", array(), $conf->entity, 0, 0, 1, 0, 0, 0,
'',
'other');
396 $pictohelp =
'<span class="fa fa-question-circle"></span>';
397 print
'<tr class="oddeven"><td>' . str_replace(
'{picto}', $pictohelp, $langs->trans(
"DisableLinkToHelp",
'{picto}')) .
'</td><td>';
398 print
ajax_constantonoff(
"MAIN_HELP_DISABLELINK", array(), $conf->entity, 0, 0, 1, 0, 0, 0,
'',
'other');
404 print
'<tr class="oddeven"><td>' . $langs->trans(
"DefaultMaxSizeList") .
'</td><td><input class="flat" name="main_size_liste_limit" size="4" value="' . $conf->global->MAIN_SIZE_LISTE_LIMIT .
'"></td>';
408 print
'<tr class="oddeven"><td>' . $langs->trans(
"DefaultMaxSizeShortList") .
'</td><td><input class="flat" name="main_size_shortliste_limit" size="4" value="' . $conf->global->MAIN_SIZE_SHORTLIST_LIMIT .
'"></td>';
420 print
'<tr class="oddeven"><td>' . $langs->trans(
"WeekStartOnDay") .
'</td><td>';
421 print $formother->select_dayofweek((isset($conf->global->MAIN_START_WEEK) ? $conf->global->MAIN_START_WEEK :
'1'),
'MAIN_START_WEEK', 0);
426 print
'<tr class="oddeven"><td>' . $langs->trans(
"DefaultWorkingDays") .
'</td><td>';
427 print
'<input type="text" name="MAIN_DEFAULT_WORKING_DAYS" size="5" value="' . (isset($conf->global->MAIN_DEFAULT_WORKING_DAYS) ? $conf->global->MAIN_DEFAULT_WORKING_DAYS :
'1-5') .
'">';
432 print
'<tr class="oddeven"><td>' . $langs->trans(
"DefaultWorkingHours") .
'</td><td>';
433 print
'<input type="text" name="MAIN_DEFAULT_WORKING_HOURS" size="5" value="' . (isset($conf->global->MAIN_DEFAULT_WORKING_HOURS) ? $conf->global->MAIN_DEFAULT_WORKING_HOURS :
'9-18') .
'">';
438 print
'<tr class="oddeven"><td>' . $langs->trans(
"FirstnameNamePosition") .
'</td><td>';
439 $array = array(0 => $langs->trans(
"Firstname") .
' ' . $langs->trans(
"Lastname"), 1 => $langs->trans(
"Lastname") .
' ' . $langs->trans(
"Firstname"));
440 print
$form->selectarray(
'MAIN_FIRSTNAME_NAME_POSITION', $array, (isset($conf->global->MAIN_FIRSTNAME_NAME_POSITION) ? $conf->global->MAIN_FIRSTNAME_NAME_POSITION : 0));
445 print
'<tr class="oddeven"><td>' . $langs->trans(
"HideUnauthorizedMenu") .
'</td><td>';
447 print
ajax_constantonoff(
"MAIN_MENU_HIDE_UNAUTHORIZED", array(), $conf->entity, 0, 0, 1, 0, 0, 0,
'',
'other');
452 print
'<tr class="oddeven"><td>' . $langs->trans(
"ButtonHideUnauthorized") .
'</td><td>';
454 print
ajax_constantonoff(
"MAIN_BUTTON_HIDE_UNAUTHORIZED", array(), $conf->entity, 0, 0, 1, 0, 0, 0,
'',
'other');
468 print
'<tr class="oddeven"><td>';
469 print
$form->textwithpicto($langs->trans(
"ShowBugTrackLink", $langs->transnoentitiesnoconv(
"FindBug")), $langs->trans(
"ShowBugTrackLinkDesc"));
471 print
'<input type="text" name="MAIN_BUGTRACK_ENABLELINK" value="' . (empty($conf->global->MAIN_BUGTRACK_ENABLELINK) ?
'' : $conf->global->MAIN_BUGTRACK_ENABLELINK) .
'">';
476 print
'<tr class="oddeven"><td>' .
$form->textwithpicto($langs->trans(
"DisableJavascript"), $langs->trans(
"DisableJavascriptNote")) .
'</td><td>';
477 print
ajax_constantonoff(
"MAIN_DISABLE_JAVASCRIPT", array(), $conf->entity, 0, 0, 1, 0, 0, 0,
'',
'other');
481 print
'</table>' .
"\n";
486 if ($mode ==
'template') {
492 if ($mode ==
'dashboard') {
493 print
'<div class="div-table-responsive-no-min">';
494 print
'<table summary="blockdashboard" class="noborder centpercent editmode tableforfield">';
500 print
'<tr class="oddeven width25p"><td>';
501 $texthelp = $langs->trans(
"FollowingConstantsWillBeSubstituted") .
'<br>';
502 foreach ($substitutionarray as $key => $val) {
503 $texthelp .= $key .
'<br>';
505 print
$form->textwithpicto($langs->trans(
"MessageOfDay"), $texthelp, 1,
'help',
'', 0, 2,
'tooltipmessageofday');
509 $doleditor =
new DolEditor(
'main_motd', (isset($conf->global->MAIN_MOTD) ? $conf->global->MAIN_MOTD :
''),
'', 142,
'dolibarr_notes',
'In',
false,
true,
true, ROWS_4,
'90%');
510 $doleditor->Create();
512 print
'</td></tr>' .
"\n";
526 print
'<div class="div-table-responsive-no-min">';
527 print
'<table summary="blockdashboard" class="noborder centpercent editmode tableforfield">';
529 print
'<tr class="liste_titre"><td class="titlefieldmiddle">';
530 print $langs->trans(
"DashboardDisableBlocks");
531 print
'</td><td class="titlefieldmiddle">';
534 print
'<tr class="oddeven"><td>' . $langs->trans(
'DashboardDisableGlobal') .
'</td><td>';
535 print
ajax_constantonoff(
"MAIN_DISABLE_GLOBAL_WORKBOARD", array(), $conf->entity, 0, 0, 1, 0, 0, 0,
'_red',
'dashboard');
539 if (empty($conf->global->MAIN_DISABLE_GLOBAL_WORKBOARD)) {
541 print
'<tr class="oddeven"><td>' . $langs->trans(
'MAIN_DISABLE_METEO') .
'</td><td>';
542 print
ajax_constantonoff(
"MAIN_DISABLE_METEO", array(), $conf->entity, 0, 0, 1, 0, 0, 0,
'_red',
'dashboard');
547 print
'<tr class="oddeven"><td>' . $langs->trans(
'DashboardDisableBlockAgenda') .
'</td><td>';
548 print
ajax_constantonoff(
"MAIN_DISABLE_BLOCK_AGENDA", array(), $conf->entity, 0, 0, 1, 0, 0, 0,
'_red',
'dashboard');
553 print
'<tr class="oddeven"><td>' . $langs->trans(
'DashboardDisableBlockProject') .
'</td><td>';
554 print
ajax_constantonoff(
"MAIN_DISABLE_BLOCK_PROJECT", array(), $conf->entity, 0, 0, 1, 0, 0, 0,
'_red',
'dashboard');
559 print
'<tr class="oddeven"><td>' . $langs->trans(
'DashboardDisableBlockCustomer') .
'</td><td>';
560 print
ajax_constantonoff(
"MAIN_DISABLE_BLOCK_CUSTOMER", array(), $conf->entity, 0, 0, 1, 0, 0, 0,
'_red',
'dashboard');
565 print
'<tr class="oddeven"><td>' . $langs->trans(
'DashboardDisableBlockSupplier') .
'</td><td>';
566 print
ajax_constantonoff(
"MAIN_DISABLE_BLOCK_SUPPLIER", array(), $conf->entity, 0, 0, 1, 0, 0, 0,
'_red',
'dashboard');
571 print
'<tr class="oddeven"><td>' . $langs->trans(
'DashboardDisableBlockContract') .
'</td><td>';
572 print
ajax_constantonoff(
"MAIN_DISABLE_BLOCK_CONTRACT", array(), $conf->entity, 0, 0, 1, 0, 0, 0,
'_red',
'dashboard');
577 print
'<tr class="oddeven"><td>' . $langs->trans(
'DashboardDisableBlockTicket') .
'</td><td>';
578 print
ajax_constantonoff(
"MAIN_DISABLE_BLOCK_TICKET", array(), $conf->entity, 0, 0, 1, 0, 0, 0,
'_red',
'dashboard');
583 print
'<tr class="oddeven"><td>' . $langs->trans(
'DashboardDisableBlockBank') .
'</td><td>';
584 print
ajax_constantonoff(
"MAIN_DISABLE_BLOCK_BANK", array(), $conf->entity, 0, 0, 1, 0, 0, 0,
'_red',
'dashboard');
589 print
'<tr class="oddeven"><td>' . $langs->trans(
'DashboardDisableBlockAdherent') .
'</td><td>';
590 print
ajax_constantonoff(
"MAIN_DISABLE_BLOCK_ADHERENT", array(), $conf->entity, 0, 0, 1, 0, 0, 0,
'_red',
'dashboard');
595 print
'<tr class="oddeven"><td>' . $langs->trans(
'DashboardDisableBlockExpenseReport') .
'</td><td>';
596 print
ajax_constantonoff(
"MAIN_DISABLE_BLOCK_EXPENSEREPORT", array(), $conf->entity, 0, 0, 1, 0, 0, 0,
'_red',
'dashboard');
601 print
'<tr class="oddeven"><td>' . $langs->trans(
'DashboardDisableBlockHoliday') .
'</td><td>';
602 print
ajax_constantonoff(
"MAIN_DISABLE_BLOCK_HOLIDAY", array(), $conf->entity, 0, 0, 1, 0, 0, 0,
'_red',
'dashboard');
607 print
'</table>' .
"\n";
612 if ($mode ==
'login') {
614 print
'<div class="div-table-responsive-no-min">';
615 print
'<table summary="edit" class="noborder centpercent editmode tableforfield">';
617 print
'<tr class="liste_titre"><td class="titlefieldmax45">';
618 print $langs->trans(
"Parameter");
620 print $langs->trans(
"Value");
624 print
'<tr class="oddeven"><td>' . $langs->trans(
"DisableLinkToHelpCenter") .
'</td><td>';
625 print
ajax_constantonoff(
"MAIN_HELPCENTER_DISABLELINK", array(), $conf->entity, 0, 0, 0, 0, 0, 0,
'',
'login');
632 print
'<tr class="oddeven"><td>';
633 $texthelp = $langs->trans(
"FollowingConstantsWillBeSubstituted") .
'<br>';
634 foreach ($substitutionarray as $key => $val) {
635 $texthelp .= $key .
'<br>';
637 print
$form->textwithpicto($langs->trans(
"MessageLogin"), $texthelp, 1,
'help',
'', 0, 2,
'tooltipmessagelogin');
639 $doleditor =
new DolEditor(
'main_home', (isset($conf->global->MAIN_HOME) ? $conf->global->MAIN_HOME :
''),
'', 142,
'dolibarr_notes',
'In',
false,
true,
true, ROWS_4,
'90%');
640 $doleditor->Create();
641 print
'</td></tr>' .
"\n";
644 print
'<tr class="oddeven"><td><label for="imagebackground">' . $langs->trans(
"BackgroundImageLogin") .
' (png,jpg)</label></td><td>';
645 print
'<div class="centpercent inline-block">';
647 if (!empty($conf->global->ADD_UNSPLASH_LOGIN_BACKGROUND)) {
648 $disabled =
' disabled="disabled"';
651 $maxmin = $maxfilesizearray[
'maxmin'];
653 print
'<input type="hidden" name="MAX_FILE_SIZE" value="'.($maxmin * 1024).
'">';
655 print
'<input type="file" class="flat maxwidthinputfileonsmartphone" name="imagebackground" id="imagebackground"' . $disabled .
'>';
657 print
'(' . $langs->trans(
"DisabledByOptionADD_UNSPLASH_LOGIN_BACKGROUND") .
') ';
659 if (!empty($conf->global->MAIN_LOGIN_BACKGROUND)) {
660 print
'<a class="reposition" href="' . $_SERVER[
"PHP_SELF"] .
'?action=removebackgroundlogin&token='.newToken().
'&mode=login">' .
img_delete($langs->trans(
"Delete")) .
'</a>';
661 if (file_exists($conf->mycompany->dir_output .
'/logos/' . $conf->global->MAIN_LOGIN_BACKGROUND)) {
663 print
'<img class="paddingleft valignmiddle" width="100" src="' . DOL_URL_ROOT .
'/viewimage.php?modulepart=mycompany&file=' . urlencode(
'logos/' . $conf->global->MAIN_LOGIN_BACKGROUND) .
'">';
666 print
'<img class="paddingleft valignmiddle" width="100" src="' . DOL_URL_ROOT .
'/public/theme/common/nophoto.png">';
671 print
'</table>' .
"\n";
675 print
'<div class="center">';
676 print
'<input class="button button-save reposition" type="submit" name="submit" value="' . $langs->trans(
"Save") .
'">';
677 print
'<input class="button button-cancel reposition" type="submit" name="cancel" value="' . $langs->trans(
"Cancel") .
'">';
dolibarr_set_const($db, $name, $value, $type='chaine', $visible=0, $note='', $entity=1)
Insert a parameter (key,value) into database (delete old key then insert it again).
dolibarr_del_const($db, $name, $entity=1)
Delete a constant.
ihm_prepare_head()
Prepare array with list of tabs.
if($actionsave) if(!isset($conf->global->MAIN_AGENDA_EXPORT_PAST_DELAY)) $wikihelp
View.
ajax_constantonoff($code, $input=array(), $entity=null, $revertonoff=0, $strict=0, $forcereload=0, $marginleftonlyshort=2, $forcenoajax=0, $setzeroinsteadofdel=0, $suffix='', $mode='', $morecss='')
On/off button for constant.
if(!defined('NOREQUIRESOC')) if(!defined('NOREQUIRETRAN')) if(!defined('NOTOKENRENEWAL')) if(!defined('NOREQUIREMENU')) if(!defined('NOREQUIREHTML')) if(!defined('NOREQUIREAJAX')) llxHeader()
Empty header.
Class to manage a WYSIWYG editor.
if($cancel &&! $id) if($action=='add' &&! $cancel) if($action=='delete') if($id) $form
Actions.
dol_delete_file($file, $disableglob=0, $nophperrors=0, $nohook=0, $object=null, $allowdotdot=false, $indexdatabase=1, $nolog=0)
Remove a file or several files with a mask.
dol_move_uploaded_file($src_file, $dest_file, $allowoverwrite, $disablevirusscan=0, $uploaderrorcode=0, $nohook=0, $varfiles='addedfile', $upload_dir='')
Make control on an uploaded file from an GUI page and move it to final destination.
colorStringToArray($stringcolor, $colorifnotfound=array(88, 88, 88))
Convert a string RGB value ('FFFFFF', '255,255,255') into an array RGB array(255,255,...
load_fiche_titre($titre, $morehtmlright='', $picto='generic', $pictoisfullpath=0, $id='', $morecssontable='', $morehtmlcenter='')
Load a title with picto.
dol_get_fiche_head($links=array(), $active='', $title='', $notab=0, $picto='', $pictoisfullpath=0, $morehtmlright='', $morecss='', $limittoshow=0, $moretabssuffix='')
Show tabs of a record.
img_delete($titlealt='default', $other='class="pictodelete"', $morecss='')
Show delete logo.
setEventMessages($mesg, $mesgs, $style='mesgs', $messagekey='')
Set event messages in dol_events session object.
getDolGlobalInt($key, $default=0)
Return dolibarr global constant int value.
img_picto($titlealt, $picto, $moreatt='', $pictoisfullpath=false, $srconly=0, $notitle=0, $alt='', $morecss='', $marginleftonlyshort=2)
Show picto whatever it's its name (generic function)
dol_htmlcleanlastbr($stringtodecode)
This function remove all ending and br at end.
complete_substitutions_array(&$substitutionarray, $outputlangs, $object=null, $parameters=null, $callfunc="completesubstitutionarray")
Complete the $substitutionarray with more entries coming from external module that had set the "subst...
GETPOST($paramname, $check='alphanohtml', $method=0, $filter=null, $options=null, $noreplace=0)
Return value of a param into GET or POST supervariable.
getCommonSubstitutionArray($outputlangs, $onlykey=0, $exclude=null, $object=null)
Return array of possible common substitutions.
GETPOSTISSET($paramname)
Return true if we are in a context of submitting the parameter $paramname from a POST of a form.
dol_syslog($message, $level=LOG_INFO, $ident=0, $suffixinfilename='', $restricttologhandler='', $logcontext=null)
Write log message into outputs.
dol_mkdir($dir, $dataroot='', $newmask='')
Creation of a directory (this can create recursive subdir)
image_format_supported($file, $acceptsvg=0)
Return if a filename is file name of a supported image format.
getMaxFileSizeArray()
Return the max allowed for file upload.
accessforbidden($message='', $printheader=1, $printfooter=1, $showonlymessage=0, $params=null)
Show a message to say access is forbidden and stop program.
showSkins($fuser, $edit=0, $foruserprofile=false)
Show list of themes.