33require
'../main.inc.php';
42require_once DOL_DOCUMENT_ROOT.
'/core/lib/usergroups.lib.php';
43require_once DOL_DOCUMENT_ROOT.
'/core/lib/admin.lib.php';
44require_once DOL_DOCUMENT_ROOT.
'/core/lib/images.lib.php';
45require_once DOL_DOCUMENT_ROOT.
'/core/lib/files.lib.php';
46require_once DOL_DOCUMENT_ROOT.
'/core/lib/functions2.lib.php';
47require_once DOL_DOCUMENT_ROOT.
'/core/class/html.formother.class.php';
48require_once DOL_DOCUMENT_ROOT.
'/core/class/html.formadmin.class.php';
51$langs->loadLangs(array(
'admin',
'languages',
'other',
'companies',
'products',
'members',
'projects',
'hrm',
'agenda'));
57$action =
GETPOST(
'action',
'aZ09');
58$contextpage =
GETPOST(
'contextpage',
'aZ') ?
GETPOST(
'contextpage',
'aZ') :
'adminihm';
59$mode =
GETPOST(
'mode',
'aZ09') ?
GETPOST(
'mode',
'aZ09') :
'other';
61if (!defined(
"MAIN_MOTD")) {
62 define(
"MAIN_MOTD",
"");
73$reshook = $hookmanager->executeHooks(
'doActions', $parameters, $object, $action);
78if (
GETPOST(
'cancel',
'alpha')) {
84if (preg_match(
'/^(set|del)_([A-Z_]+)$/', $action, $regs)) {
85 if ($regs[1] ==
'set') {
92if ($action ==
'removebackgroundlogin' &&
getDolGlobalString(
'MAIN_LOGIN_BACKGROUND')) {
94 require_once DOL_DOCUMENT_ROOT.
'/core/lib/files.lib.php';
96 $logofile = $conf->mycompany->dir_output.
'/logos/' .
getDolGlobalString(
'MAIN_LOGIN_BACKGROUND');
112if ($action ==
'update') {
115 if ($mode ==
'template') {
121 if (GETPOSTISSET(
'THEME_ELDY_USECOMOACTROW')) {
122 dolibarr_set_const($db,
"THEME_ELDY_USECOMOACTROW",
GETPOST(
'THEME_ELDY_USECOMOACTROW'),
'chaine', 0,
'', $conf->entity);
125 if (GETPOSTISSET(
'THEME_DARKMODEENABLED')) {
126 $val =
GETPOST(
'THEME_DARKMODEENABLED');
131 dolibarr_set_const($db,
"THEME_DARKMODEENABLED", $val,
'chaine', 0,
'', $conf->entity);
135 if (GETPOSTISSET(
'THEME_TOPMENU_DISABLE_IMAGE')) {
136 $val =
GETPOST(
'THEME_TOPMENU_DISABLE_IMAGE');
140 dolibarr_set_const($db,
'THEME_TOPMENU_DISABLE_IMAGE',
GETPOST(
'THEME_TOPMENU_DISABLE_IMAGE'),
'chaine', 0,
'', $conf->entity);
144 if (GETPOSTISSET(
'THEME_ELDY_BORDER_RADIUS')) {
145 $val =
GETPOST(
'THEME_ELDY_BORDER_RADIUS');
160 dolibarr_set_const($db,
'THEME_ELDY_TOPMENU_BACK1', $val,
'chaine', 0,
'', $conf->entity);
167 dolibarr_set_const($db,
'THEME_ELDY_VERMENU_BACK1', $val,
'chaine', 0,
'', $conf->entity);
174 dolibarr_set_const($db,
'THEME_ELDY_TEXTTITLENOTAB', $val,
'chaine', 0,
'', $conf->entity);
181 dolibarr_set_const($db,
'THEME_ELDY_BACKTITLE1', $val,
'chaine', 0,
'', $conf->entity);
188 dolibarr_set_const($db,
'THEME_ELDY_TEXTTITLE', $val,
'chaine', 0,
'', $conf->entity);
195 dolibarr_set_const($db,
'THEME_ELDY_TEXTTITLELINK', $val,
'chaine', 0,
'', $conf->entity);
202 dolibarr_set_const($db,
'THEME_ELDY_LINEIMPAIR1', $val,
'chaine', 0,
'', $conf->entity);
208 dolibarr_set_const($db,
'THEME_ELDY_LINEIMPAIR2', $val,
'chaine', 0,
'', $conf->entity);
215 dolibarr_set_const($db,
'THEME_ELDY_LINEPAIR1', $val,
'chaine', 0,
'', $conf->entity);
221 dolibarr_set_const($db,
'THEME_ELDY_LINEPAIR2', $val,
'chaine', 0,
'', $conf->entity);
235 dolibarr_set_const($db,
"THEME_ELDY_USE_HOVER", $val,
'chaine', 0,
'', $conf->entity);
242 dolibarr_set_const($db,
"THEME_ELDY_USE_CHECKED", $val,
'chaine', 0,
'', $conf->entity);
249 dolibarr_set_const($db,
'THEME_ELDY_BTNACTION', $val,
'chaine', 0,
'', $conf->entity);
256 dolibarr_set_const($db,
'THEME_ELDY_TEXTBTNACTION', $val,
'chaine', 0,
'', $conf->entity);
262 if ($mode ==
'dashboard') {
268 if ($mode ==
'other') {
275 if (GETPOSTISSET(
"MAIN_CHECKBOX_LEFT_COLUMN")) {
284 dolibarr_set_const($db,
"MAIN_DEFAULT_WORKING_DAYS",
GETPOST(
"MAIN_DEFAULT_WORKING_DAYS",
'alphanohtml'),
'chaine', 0,
'', $conf->entity);
285 dolibarr_set_const($db,
"MAIN_DEFAULT_WORKING_HOURS",
GETPOST(
"MAIN_DEFAULT_WORKING_HOURS",
'alphanohtml'),
'chaine', 0,
'', $conf->entity);
287 dolibarr_set_const($db,
"MAIN_BUGTRACK_ENABLELINK",
GETPOST(
"MAIN_BUGTRACK_ENABLELINK",
'alpha'),
'chaine', 0,
'', $conf->entity);
289 dolibarr_set_const($db,
"MAIN_FIRSTNAME_NAME_POSITION",
GETPOST(
"MAIN_FIRSTNAME_NAME_POSITION",
'aZ09'),
'chaine', 0,
'', $conf->entity);
295 if ($mode ==
'login') {
299 $varforimage =
'imagebackground';
300 $dirforimage = $conf->mycompany->dir_output .
'/logos/';
301 if ($_FILES[$varforimage][
"tmp_name"]) {
303 if (preg_match(
'/([^\\/:]+)$/i', $_FILES[$varforimage][
"name"], $reg)) {
304 $original_file = $reg[1];
308 dol_syslog(
"Move file " . $_FILES[$varforimage][
"tmp_name"] .
" to " . $dirforimage . $original_file);
309 if (!is_dir($dirforimage)) {
312 $result =
dol_move_uploaded_file($_FILES[$varforimage][
"tmp_name"], $dirforimage . $original_file, 1, 0, $_FILES[$varforimage][
'error']);
314 dolibarr_set_const($db,
"MAIN_LOGIN_BACKGROUND", $original_file,
'chaine', 0,
'', $conf->entity);
315 } elseif (preg_match(
'/^ErrorFileIsInfectedWithAVirus/', $result)) {
317 $langs->load(
"errors");
318 $tmparray = explode(
':', $result);
319 setEventMessages($langs->trans(
'ErrorFileIsInfectedWithAVirus', $tmparray[1]),
null,
'errors');
326 $langs->load(
"errors");
337 if ($mode ==
'css') {
338 $csscontent =
GETPOST(
'MAIN_IHM_CUSTOM_CSS',
'restricthtml');
341 dolibarr_set_const($db,
"MAIN_IHM_CUSTOM_CSS", $csscontent,
'chaine', 0,
'', $conf->entity);
346 $_SESSION[
"mainmenu"] =
"";
348 if (
GETPOST(
'dol_resetcache')) {
352 header(
"Location: ".$_SERVER[
"PHP_SELF"].
"?mainmenu=home&leftmenu=setup&mode=".$mode.(GETPOSTISSET(
'page_y') ?
'&page_y='.GETPOSTINT(
'page_y') :
''));
361$wikihelp =
'EN:First_setup|FR:Premiers_paramétrages|ES:Primeras_configuraciones';
365 $langs->trans(
"Setup"),
371 '/includes/ace/src/ace.js',
372 '/includes/ace/src/ext-statusbar.js',
373 '/includes/ace/src/ext-language_tools.js',
380$form =
new Form($db);
386print
'<span class="opacitymedium">'.$langs->trans(
"DisplayDesc").
"</span><br>\n";
390require_once DOL_DOCUMENT_ROOT.
'/core/class/doleditor.class.php';
392print
'<form enctype="multipart/form-data" method="POST" action="'.dolBuildUrl($_SERVER[
"PHP_SELF"]).
'">';
393print
'<input type="hidden" name="token" value="'.newToken().
'">';
394print
'<input type="hidden" name="action" value="update">';
395print
'<input type="hidden" name="page_y" value="">';
396print
'<input type="hidden" id="mode" name="mode" value="'.dol_escape_htmltag($mode).
'">';
397print
'<input type="hidden" name="dol_resetcache" value="1">';
407if ($mode ==
'other') {
408 print
'<div class="div-table-responsive-no-min">';
409 print
'<table summary="edit" class="noborder centpercent editmode tableforfield">';
411 print
'<tr class="liste_titre"><td class="titlefieldmiddle">';
412 print $langs->trans(
"Language");
417 print
'<tr class="oddeven"><td>'.$langs->trans(
"DefaultLanguage").
'</td><td>';
418 print
img_picto(
'',
'language',
'class="pictofixedwidth"');
419 print $formadmin->select_language(
getDolGlobalString(
'MAIN_LANG_DEFAULT'),
'MAIN_LANG_DEFAULT', 1, array(),
'', 0, 0,
'minwidth300', 2);
425 print
'<tr class="oddeven"><td>' . $langs->trans(
"EnableMultilangInterface") .
'</td><td>';
426 print ajax_constantonoff(
"MAIN_MULTILANGS", array(), $conf->entity, 0, 0, 1, 0, 0, 0,
'',
'language');
430 print
'</table>' .
"\n";
433 print
'<div class="center">';
434 print
'<input class="button button-save reposition" type="submit" name="submit" value="' . $langs->trans(
"Save") .
'">';
435 print
'<input class="button button-cancel reposition" type="submit" name="cancel" value="' . $langs->trans(
"Cancel") .
'">';
442 print
'<div class="div-table-responsive-no-min">';
443 print
'<table summary="otherparameters" class="noborder centpercent editmode tableforfield">';
445 print
'<tr class="liste_titre"><td class="titlefieldmiddle">';
446 print $langs->trans(
"Miscellaneous");
451 if (!empty($conf->use_javascript_ajax)) {
453 print
'<tr class="oddeven"><td>' . $langs->trans(
"ShowQuickAddLink") .
'</td><td>';
454 print ajax_constantonoff(
"MAIN_USE_TOP_MENU_QUICKADD_DROPDOWN", array(), $conf->entity, 0, 0, 1, 0, 0, 0,
'',
'other');
460 $pictohelp =
'<span class="fa fa-question-circle"></span>';
461 print
'<tr class="oddeven"><td>' . str_replace(
'{picto}', $pictohelp, $langs->trans(
"DisableLinkToHelp",
'{picto}')) .
'</td><td>';
462 print ajax_constantonoff(
"MAIN_HELP_DISABLELINK", array(), $conf->entity, 0, 0, 1, 0, 0, 0,
'',
'other');
467 print
'<tr class="oddeven"><td>' . $langs->trans(
"DefaultMaxSizeList") .
'</td><td><input class="flat width50" name="MAIN_SIZE_LISTE_LIMIT" value="';
473 print
' <span class="opacitymedium">('.$langs->trans(
"Automatic").
')</span>';
479 print
'<tr class="oddeven"><td>' . $langs->trans(
"DefaultMaxSizeShortList") .
'</td><td><input class="flat width50" name="MAIN_SIZE_SHORTLIST_LIMIT" value="' .
getDolGlobalString(
'MAIN_SIZE_SHORTLIST_LIMIT') .
'"></td>';
483 print
'<tr class="oddeven"><td>' . $langs->trans(
"MAIN_CHECKBOX_LEFT_COLUMN") .
'</td><td>';
484 print ajax_constantonoff(
"MAIN_CHECKBOX_LEFT_COLUMN", array(), $conf->entity, 0, 0, 1, 0, 0, 1,
'',
'other');
489 print
'<tr class="oddeven"><td>' . $langs->trans(
"WeekStartOnDay") .
'</td><td>';
490 print $formother->select_dayofweek(
getDolGlobalString(
'MAIN_START_WEEK',
'1'),
'MAIN_START_WEEK', 0);
495 print
'<tr class="oddeven"><td>' . $langs->trans(
"DefaultWorkingDays") .
'</td><td>';
496 print
'<input type="text" name="MAIN_DEFAULT_WORKING_DAYS" size="5" value="' .
getDolGlobalString(
'MAIN_DEFAULT_WORKING_DAYS',
'1-5') .
'">';
501 print
'<tr class="oddeven"><td>' . $langs->trans(
"DefaultWorkingHours") .
'</td><td>';
502 print
'<input type="text" name="MAIN_DEFAULT_WORKING_HOURS" size="5" value="' .
getDolGlobalString(
'MAIN_DEFAULT_WORKING_HOURS',
'9-18') .
'">';
507 print
'<tr class="oddeven"><td>' . $langs->trans(
"FirstnameNamePosition") .
'</td><td>';
508 $array = array(0 => $langs->trans(
"Firstname") .
' ' . $langs->trans(
"Lastname"), 1 => $langs->trans(
"Lastname") .
' ' . $langs->trans(
"Firstname"));
509 print $form->selectarray(
'MAIN_FIRSTNAME_NAME_POSITION', $array,
getDolGlobalInt(
'MAIN_FIRSTNAME_NAME_POSITION', 0));
514 print
'<tr class="oddeven"><td>' . $langs->trans(
"HideUnauthorizedMenu") .
'</td><td>';
515 print ajax_constantonoff(
"MAIN_MENU_HIDE_UNAUTHORIZED", array(), $conf->entity, 0, 0, 1, 0, 0, 0,
'',
'other');
520 print
'<tr class="oddeven"><td>' . $langs->trans(
"ButtonHideUnauthorized") .
'</td><td>';
521 print ajax_constantonoff(
"MAIN_BUTTON_HIDE_UNAUTHORIZED", array(), $conf->entity, 0, 0, 1, 0, 0, 0,
'',
'other');
536 print
'<tr class="oddeven"><td>' .
img_picto(
'',
'search',
'class="pictofixedwidth"').
' '.$langs->trans(
"ShowSearchAreaInTopMenu") .
'</td><td>';
537 print ajax_constantonoff(
"MAIN_USE_TOP_MENU_SEARCH_DROPDOWN", array(), $conf->entity, 0, 0, 1, 0, 0, 0,
'',
'other');
542 print
'<tr class="oddeven"><td>';
543 print $form->textwithpicto($langs->trans(
"ShowBugTrackLink", $langs->transnoentitiesnoconv(
"FindBug")), $langs->trans(
"ShowBugTrackLinkDesc"));
545 print
'<input type="text" name="MAIN_BUGTRACK_ENABLELINK" value="' .
getDolGlobalString(
'MAIN_BUGTRACK_ENABLELINK') .
'">';
550 print
'<tr class="oddeven"><td>' . $form->textwithpicto($langs->trans(
"DisableJavascript"), $langs->trans(
"DisableJavascriptNote")) .
'</td><td>';
551 print ajax_constantonoff(
"MAIN_DISABLE_JAVASCRIPT", array(), $conf->entity, 0, 0, 1, 0, 0, 0,
'',
'other');
555 print
'</table>' .
"\n";
560if ($mode ==
'template') {
566if ($mode ==
'dashboard') {
567 print
'<div class="div-table-responsive-no-min">';
568 print
'<table summary="blockdashboard" class="noborder centpercent editmode tableforfield">';
571 $substitutionarray = getCommonSubstitutionArray($langs, 0, array(
'object',
'objectamount'));
574 print
'<tr class="oddeven width25p"><td>';
575 $texthelp = $langs->trans(
"FollowingConstantsWillBeSubstituted") .
'<br>';
576 foreach ($substitutionarray as $key => $val) {
577 $texthelp .= $key .
'<br>';
579 print $form->textwithpicto($langs->trans(
"MessageOfDay"), $texthelp, 1,
'help',
'', 0, 2,
'tooltipmessageofday');
583 $doleditor =
new DolEditor(
'main_motd',
getDolGlobalString(
'MAIN_MOTD'),
'', 142,
'dolibarr_notes',
'In',
false,
true,
true, ROWS_4,
'90%');
584 $doleditor->Create();
586 print
'</td></tr>'.
"\n";
593 print
'<div class="div-table-responsive-no-min">';
594 print
'<table summary="blockdashboard" class="noborder centpercent editmode tableforfield">';
596 print
'<tr class="liste_titre"><td class="titlefieldmiddle">';
597 print $langs->trans(
"DashboardDisableBlocks");
598 print
'</td><td class="titlefieldmiddle">';
601 print
'<tr class="oddeven"><td>' . $langs->trans(
'DashboardDisableGlobal') .
'</td><td>';
602 print ajax_constantonoff(
"MAIN_DISABLE_GLOBAL_WORKBOARD", array(), $conf->entity, 0, 0, 1, 0, 0, 0,
'_red',
'dashboard');
608 print
'<tr class="oddeven"><td>' . $langs->trans(
'MAIN_DISABLE_METEO') .
'</td><td>';
609 print ajax_constantonoff(
"MAIN_DISABLE_METEO", array(), $conf->entity, 0, 0, 0, 0, 0, 0,
'_red',
'dashboard');
614 print
'<tr class="oddeven"><td>' . $langs->trans(
'DashboardDisableBlockAgenda') .
'</td><td>';
615 print ajax_constantonoff(
"MAIN_DISABLE_BLOCK_AGENDA", array(), $conf->entity, 0, 0, 0, 0, 0, 0,
'_red',
'dashboard');
620 print
'<tr class="oddeven"><td>' . $langs->trans(
'DashboardDisableBlockProject') .
'</td><td>';
621 print ajax_constantonoff(
"MAIN_DISABLE_BLOCK_PROJECT", array(), $conf->entity, 0, 0, 0, 0, 0, 0,
'_red',
'dashboard');
626 print
'<tr class="oddeven"><td>' . $langs->trans(
'DashboardDisableBlockCustomer') .
'</td><td>';
627 print ajax_constantonoff(
"MAIN_DISABLE_BLOCK_CUSTOMER", array(), $conf->entity, 0, 0, 0, 0, 0, 0,
'_red',
'dashboard');
632 print
'<tr class="oddeven"><td>' . $langs->trans(
'DashboardDisableBlockSupplier') .
'</td><td>';
633 print ajax_constantonoff(
"MAIN_DISABLE_BLOCK_SUPPLIER", array(), $conf->entity, 0, 0, 0, 0, 0, 0,
'_red',
'dashboard');
638 print
'<tr class="oddeven"><td>' . $langs->trans(
'DashboardDisableBlockContract') .
'</td><td>';
639 print ajax_constantonoff(
"MAIN_DISABLE_BLOCK_CONTRACT", array(), $conf->entity, 0, 0, 0, 0, 0, 0,
'_red',
'dashboard');
644 print
'<tr class="oddeven"><td>' . $langs->trans(
'DashboardDisableBlockTicket') .
'</td><td>';
645 print ajax_constantonoff(
"MAIN_DISABLE_BLOCK_TICKET", array(), $conf->entity, 0, 0, 0, 0, 0, 0,
'_red',
'dashboard');
650 print
'<tr class="oddeven"><td>' . $langs->trans(
'DashboardDisableBlockBank') .
'</td><td>';
651 print ajax_constantonoff(
"MAIN_DISABLE_BLOCK_BANK", array(), $conf->entity, 0, 0, 0, 0, 0, 0,
'_red',
'dashboard');
656 print
'<tr class="oddeven"><td>' . $langs->trans(
'DashboardDisableBlockAdherent') .
'</td><td>';
657 print ajax_constantonoff(
"MAIN_DISABLE_BLOCK_ADHERENT", array(), $conf->entity, 0, 0, 0, 0, 0, 0,
'_red',
'dashboard');
662 print
'<tr class="oddeven"><td>' . $langs->trans(
'DashboardDisableBlockExpenseReport') .
'</td><td>';
663 print ajax_constantonoff(
"MAIN_DISABLE_BLOCK_EXPENSEREPORT", array(), $conf->entity, 0, 0, 0, 0, 0, 0,
'_red',
'dashboard');
668 print
'<tr class="oddeven"><td>' . $langs->trans(
'DashboardDisableBlockHoliday') .
'</td><td>';
669 print ajax_constantonoff(
"MAIN_DISABLE_BLOCK_HOLIDAY", array(), $conf->entity, 0, 0, 0, 0, 0, 0,
'_red',
'dashboard');
674 print
'<tr class="oddeven"><td>' . $langs->trans(
'DashboardDisableBlockMrp') .
'</td><td>';
675 print ajax_constantonoff(
"MAIN_DISABLE_BLOCK_MRP", array(), $conf->entity, 0, 0, 0, 0, 0, 0,
'_red',
'dashboard');
680 print
'</table>' .
"\n";
685if ($mode ==
'login') {
687 print
'<div class="div-table-responsive-no-min">';
688 print
'<table summary="edit" class="noborder centpercent editmode tableforfield">';
690 print
'<tr class="liste_titre"><td class="titlefieldmax45">';
691 print $langs->trans(
"Parameter");
696 $substitutionarray = getCommonSubstitutionArray($langs, 0, array(
'object',
'objectamount',
'user'));
698 print
'<tr class="oddeven"><td>';
699 $texthelp = $langs->trans(
"FollowingConstantsWillBeSubstituted") .
'<br>';
700 foreach ($substitutionarray as $key => $val) {
701 $texthelp .= $key .
'<br>';
703 print $form->textwithpicto($langs->trans(
"MessageLogin"), $texthelp, 1,
'help',
'', 0, 2,
'tooltipmessagelogin');
705 $doleditor =
new DolEditor(
'main_home',
getDolGlobalString(
'MAIN_HOME'),
'', 142,
'dolibarr_notes',
'In',
false,
true,
true, ROWS_4,
'90%');
706 $doleditor->Create();
707 print
'</td></tr>' .
"\n";
710 print
'<tr class="oddeven"><td><label for="imagebackground">' . $langs->trans(
"BackgroundImageLogin") .
' (png,jpg)</label></td><td>';
711 print
'<div class="centpercent inline-block">';
714 $disabled =
' disabled="disabled"';
717 $maxmin = $maxfilesizearray[
'maxmin'];
719 print
'<input type="hidden" name="MAX_FILE_SIZE" value="'.($maxmin * 1024).
'">';
721 print
'<input type="file" class="flat maxwidthinputfileonsmartphone" name="imagebackground" id="imagebackground"' . $disabled .
'>';
723 print
'(' . $langs->trans(
"DisabledByOptionADD_UNSPLASH_LOGIN_BACKGROUND") .
') ';
726 print
'<a class="reposition" href="' . $_SERVER[
"PHP_SELF"] .
'?action=removebackgroundlogin&token='.newToken().
'&mode=login">' .
img_delete($langs->trans(
"Delete")) .
'</a>';
727 if (file_exists($conf->mycompany->dir_output .
'/logos/' .
getDolGlobalString(
'MAIN_LOGIN_BACKGROUND'))) {
729 print
'<img class="marginleftonly boxshadow valignmiddle" width="100" src="' . DOL_URL_ROOT .
'/viewimage.php?modulepart=mycompany&file=' . urlencode(
'logos/' .
getDolGlobalString(
'MAIN_LOGIN_BACKGROUND')) .
'">';
732 print
'<img class="marginleftonly valignmiddle" width="100" src="' . DOL_URL_ROOT .
'/public/theme/common/nophoto.png">';
737 print
'</table>' .
"\n";
742 print
'<div class="div-table-responsive-no-min">';
743 print
'<table summary="edit" class="noborder centpercent editmode tableforfield">';
745 print
'<tr class="liste_titre">';
746 print
'<td colspan="2">';
751 $doleditor =
new DolEditor(
'MAIN_IHM_CUSTOM_CSS', $customcssValue,
'80%', 400,
'Basic',
'In',
true,
false,
'ace', 10,
'90%');
752 $doleditor->Create(0,
'',
true,
'css',
'css');
753 print
'</td></tr>'.
"\n";
755 print
'</table>'.
"\n";
760print
'<div class="center">';
761print
'<input class="button button-save reposition buttonforacesave" type="submit" name="submit" value="' . $langs->trans(
"Save") .
'">';
762print
'<input class="button button-cancel reposition" type="submit" name="cancel" value="' . $langs->trans(
"Cancel") .
'">';
if(! $sortfield) if(! $sortorder) $object
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.
llxFooter($comment='', $zone='private', $disabledoutputofmessages=0)
Empty footer.
if(!defined('NOREQUIRESOC')) if(!defined( 'NOREQUIRETRAN')) if(!defined('NOTOKENRENEWAL')) if(!defined( 'NOREQUIREMENU')) if(!defined('NOREQUIREHTML')) if(!defined( 'NOREQUIREAJAX')) llxHeader($head='', $title='', $help_url='', $target='', $disablejs=0, $disablehead=0, $arrayofjs='', $arrayofcss='', $morequerystring='', $morecssonbody='', $replacemainareaby='', $disablenofollow=0, $disablenoindex=0)
Empty header.
Class to manage a WYSIWYG editor.
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, $keyforsourcefile='addedfile', $upload_dir='', $mode=0)
Check validity of a file upload from an GUI page, and move it to its 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,...
setEventMessages($mesg, $mesgs, $style='mesgs', $messagekey='', $noduplicate=0, $attop=0)
Set event messages in dol_events session object.
img_picto($titlealt, $picto, $moreatt='', $pictoisfullpath=0, $srconly=0, $notitle=0, $alt='', $morecss='', $marginleftonlyshort=2, $allowothertags=array())
Show picto whatever it's its name (generic function)
img_delete($titlealt='default', $other='class="pictodelete"', $morecss='')
Show delete logo.
GETPOSTINT($paramname, $method=0)
Return the value of a $_GET or $_POST supervariable, converted into integer.
dol_get_fiche_head($links=array(), $active='', $title='', $notab=0, $picto='', $pictoisfullpath=0, $morehtmlright='', $morecss='', $limittoshow=0, $moretabssuffix='', $dragdropfile=0, $morecssdiv='')
Show tabs of a record.
dol_string_nohtmltag($stringtoclean, $removelinefeed=1, $pagecodeto='UTF-8', $strip_tags=0, $removedoublespaces=1)
Clean a string from all HTML tags and entities.
getDolGlobalInt($key, $default=0)
Return a Dolibarr global constant int value.
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.
load_fiche_titre($title, $morehtmlright='', $picto='generic', $pictoisfullpath=0, $id='', $morecssontable='', $morehtmlcenter='', $morecssonpicto='widthpictotitle')
Load a title with picto.
getDolGlobalString($key, $default='')
Return a Dolibarr global constant string value.
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.