39 global $langs, $conf, $user, $db;
41 $langs->load(
"users");
45 $canreadperms = ($user->admin || ($user->id !=
$object->id && $user->hasRight(
'user',
'user_advance',
'readperms')) || ($user->id ==
$object->id && $user->hasRight(
'user',
'self_advance',
'readperms')));
51 $head[$h][0] = DOL_URL_ROOT.
'/user/card.php?id='.
$object->id;
52 $head[$h][1] = $langs->trans(
"User");
53 $head[$h][2] =
'user';
59 $head[$h][0] = DOL_URL_ROOT.
'/user/ldap.php?id='.
$object->id;
60 $head[$h][1] = $langs->trans(
"LDAPCard");
61 $head[$h][2] =
'ldap';
66 $head[$h][0] = DOL_URL_ROOT.
'/user/perms.php?id='.
$object->id;
67 $head[$h][1] = $langs->trans(
"Rights").(!
getDolGlobalString(
'MAIN_OPTIMIZEFORTEXTBROWSER') ?
'<span class="badge marginleftonlyshort">'.($object->nb_rights).
'</span>' :
'');
68 $head[$h][2] =
'rights';
72 $head[$h][0] = DOL_URL_ROOT.
'/user/param_ihm.php?id='.
$object->id;
73 $head[$h][1] = $langs->trans(
"UserGUISetup");
74 $head[$h][2] =
'guisetup';
77 if (isModEnabled(
'agenda')) {
79 $conf->global->AGENDA_EXT_NB = 5;
85 while ($i <= $MAXAGENDA) {
87 $name =
'AGENDA_EXT_NAME_'.$object->id.
'_'.$key;
88 $src =
'AGENDA_EXT_SRC_'.$object->id.
'_'.$key;
89 $offsettz =
'AGENDA_EXT_OFFSETTZ_'.$object->id.
'_'.$key;
90 $color =
'AGENDA_EXT_COLOR_'.$object->id.
'_'.$key;
93 if (!empty(
$object->conf->$name)) {
98 $head[$h][0] = DOL_URL_ROOT.
'/user/agenda_extsites.php?id='.
$object->id;
99 $head[$h][1] = $langs->trans(
"ExtSites").($nbagenda ?
'<span class="badge marginleftonlyshort">'.$nbagenda.
'</span>' :
'');
100 $head[$h][2] =
'extsites';
104 if (isModEnabled(
'clicktodial')) {
105 $head[$h][0] = DOL_URL_ROOT.
'/user/clicktodial.php?id='.
$object->id;
106 $head[$h][1] = $langs->trans(
"ClickToDial");
107 $head[$h][2] =
'clicktodial';
112 if ($user->socid == 0 && isModEnabled(
'notification')) {
114 $sql =
"SELECT COUNT(n.rowid) as nb";
115 $sql .=
" FROM ".MAIN_DB_PREFIX.
"notify_def as n";
116 $sql .=
" WHERE fk_user = ".((int)
$object->id);
117 $resql = $db->query($sql);
119 $num = $db->num_rows($resql);
122 $obj = $db->fetch_object($resql);
130 $langs->load(
"mails");
131 $head[$h][0] = DOL_URL_ROOT.
'/user/notify/card.php?id='.
$object->id;
132 $head[$h][1] = $langs->trans(
"NotificationsAuto");
134 $head[$h][1] .=
'<span class="badge marginleftonlyshort">'.$nbNote.
'</span>';
136 $head[$h][2] =
'notify';
146 if ((isModEnabled(
'salaries') && $user->hasRight(
'salaries',
'read'))
147 || (isModEnabled(
'hrm') && $user->hasRight(
'hrm',
'employee',
'read'))
148 || (isModEnabled(
'expensereport') && $user->hasRight(
'expensereport',
'lire') && ($user->id ==
$object->id || $user->hasRight(
'expensereport',
'readall')))
149 || (isModEnabled(
'holiday') && $user->hasRight(
'holiday',
'read') && ($user->id ==
$object->id || $user->hasRight(
'holiday',
'readall')))
152 $head[$h][0] = DOL_URL_ROOT.
'/user/bank.php?id='.
$object->id;
153 $head[$h][1] = $langs->trans(
"HRAndBank");
154 $head[$h][2] =
'bank';
159 if (empty($user->socid)) {
162 if (!empty(
$object->note_public)) {
165 if (!empty(
$object->note_private)) {
168 $head[$h][0] = DOL_URL_ROOT.
'/user/note.php?id='.
$object->id;
169 $head[$h][1] = $langs->trans(
"Note");
171 $head[$h][1] .=
'<span class="badge marginleftonlyshort">'.$nbNote.
'</span>';
173 $head[$h][2] =
'note';
177 require_once DOL_DOCUMENT_ROOT.
'/core/lib/files.lib.php';
178 require_once DOL_DOCUMENT_ROOT.
'/core/class/link.class.php';
179 $upload_dir = $conf->user->dir_output.
"/".
$object->id;
180 $nbFiles = count(
dol_dir_list($upload_dir,
'files', 0,
'',
'(\.meta|_preview.*\.png)$'));
182 $head[$h][0] = DOL_URL_ROOT.
'/user/document.php?userid='.
$object->id;
183 $head[$h][1] = $langs->trans(
"Documents");
184 if (($nbFiles + $nbLinks) > 0) {
185 $head[$h][1] .=
'<span class="badge marginleftonlyshort">'.($nbFiles + $nbLinks).
'</span>';
187 $head[$h][2] =
'document';
190 $head[$h][0] = DOL_URL_ROOT.
'/user/agenda.php?id='.
$object->id;
191 $head[$h][1] = $langs->trans(
"Events");
192 if (isModEnabled(
'agenda') && ($user->hasRight(
'agenda',
'myactions',
'read') || $user->hasRight(
'agenda',
'allactions',
'read'))) {
195 require_once DOL_DOCUMENT_ROOT.
'/core/lib/memory.lib.php';
196 $cachekey =
'count_events_user_'.$object->id;
198 if (!is_null($dataretrieved)) {
199 $nbEvent = $dataretrieved;
201 $sql =
"SELECT COUNT(ac.id) as nb";
202 $sql .=
" FROM ".MAIN_DB_PREFIX.
"actioncomm as ac";
203 $sql .=
" WHERE ac.fk_user_action = ".((int)
$object->id);
204 $sql .=
" AND ac.entity IN (".getEntity(
'agenda').
")";
205 $resql = $db->query($sql);
207 $obj = $db->fetch_object($resql);
210 dol_syslog(
'Failed to count actioncomm '.$db->lasterror(), LOG_ERR);
216 $head[$h][1] .= $langs->trans(
"Agenda");
218 $head[$h][1] .=
'<span class="badge marginleftonlyshort">'.$nbEvent.
'</span>';
221 $head[$h][2] =
'info';
344function showSkins($fuser, $edit = 0, $foruserprofile =
false)
346 global $conf, $langs, $db, $form;
348 require_once DOL_DOCUMENT_ROOT.
'/core/class/html.formother.class.php';
352 $dirthemes = array(
'/theme');
353 if (!empty($conf->modules_parts[
'theme'])) {
354 foreach ($conf->modules_parts[
'theme'] as $reldir) {
355 $dirthemes = array_merge($dirthemes, (array) ($reldir.
'theme'));
358 $dirthemes = array_unique($dirthemes);
361 $selected_theme =
'';
362 if (empty($foruserprofile)) {
365 $selected_theme = ((is_object($fuser) && !empty($fuser->conf->MAIN_THEME)) ? $fuser->conf->MAIN_THEME :
'');
369 if (empty($foruserprofile)) {
372 $hoverdisabled = (is_object($fuser) ? (empty($fuser->conf->THEME_ELDY_USE_HOVER) || $fuser->conf->THEME_ELDY_USE_HOVER ==
'0') :
'');
375 $checkeddisabled =
'';
376 if (empty($foruserprofile)) {
379 $checkeddisabled = (is_object($fuser) ? (empty($fuser->conf->THEME_ELDY_USE_CHECKED) || $fuser->conf->THEME_ELDY_USE_CHECKED ==
'0') :
'');
383 if ($foruserprofile) {
388 print
'<div class="div-table-responsive-no-min">';
389 print
'<table class="noborder centpercent'.($edit ?
' editmodeforshowskin' :
'').
'">';
392 if ($foruserprofile) {
393 print
'<tr class="liste_titre"><th class="titlefieldmiddle">'.$langs->trans(
"Parameter").
'</th><th>'.$langs->trans(
"DefaultValue").
'</th>';
394 print
'<th colspan="2"> </th>';
398 print
'<td>'.$langs->trans(
"DefaultSkin").
'</td>';
400 print
'<td class="nowrap left"><input id="check_MAIN_THEME" name="check_MAIN_THEME"'.($edit ?
'' :
' disabled').
' type="checkbox" '.($selected_theme ?
" checked" :
"").
'> <label for="check_MAIN_THEME">'.$langs->trans(
"UsePersonalValue").
'</label></td>';
401 print
'<td> </td>';
404 $dirthemestring =
'';
405 foreach ($dirthemes as $dirtheme) {
406 $dirthemestring .=
'"'.$dirtheme.
'" ';
409 print
'<tr class="liste_titre"><th class="titlefieldmiddle">';
410 print $form->textwithpicto($langs->trans(
"DefaultSkin"), $langs->trans(
"ThemeDir").
' : '.$dirthemestring);
412 print
'<th class="right">';
413 $url =
'https://www.dolistore.com/9-skins';
414 print
'<a href="'.$url.
'" target="_blank" rel="noopener noreferrer external">';
415 print $langs->trans(
'DownloadMoreSkins');
416 print
img_picto(
'',
'globe',
'class="paddingleft"');
421 print
'<tr><td colspan="'.$colspan.
'" class="center">';
424 $langs->load(
"errors");
428 print
'<table class="nobordernopadding centpercent"><tr><td><div class="center">';
431 foreach ($dirthemes as $dir) {
436 if (is_dir($dirtheme)) {
437 $handle = opendir($dirtheme);
438 if (is_resource($handle)) {
439 while (($subdir = readdir($handle)) !==
false) {
440 if (is_dir($dirtheme.
"/".$subdir) && substr($subdir, 0, 1) !=
'.'
441 && substr($subdir, 0, 3) !=
'CVS' && !preg_match(
'/common|phones/i', $subdir)) {
443 if (
getDolGlobalInt(
'MAIN_FEATURES_LEVEL') < 2 && preg_match(
'/_dev$/i', $subdir)) {
446 if (
getDolGlobalInt(
'MAIN_FEATURES_LEVEL') < 1 && preg_match(
'/_exp$/i', $subdir)) {
450 print
'<div class="inline-block" style="margin-top: 10px; margin-bottom: 10px; margin-right: 20px; margin-left: 20px;">';
451 $file = $dirtheme.
"/".$subdir.
"/thumb.png";
452 $url = $urltheme.
"/".$subdir.
"/thumb.png";
453 if (!file_exists($file)) {
454 $url = DOL_URL_ROOT.
'/public/theme/common/nophoto.png';
456 print
'<a href="'.$_SERVER[
"PHP_SELF"].($edit ?
'?action=edit&token='.newToken().
'&mode=template&theme=' :
'?theme=').$subdir.(GETPOST(
'optioncss',
'alpha', 1) ?
'&optioncss='.GETPOST(
'optioncss',
'alpha', 1) :
'').($fuser ?
'&id='.$fuser->id :
'').
'" style="font-weight: normal;" alt="'.$langs->trans(
"Preview").
'">';
457 if ($subdir == $conf->global->MAIN_THEME) {
458 $title = $langs->trans(
"ThemeCurrentlyActive");
460 $title = $langs->trans(
"ShowPreview");
462 print
'<img class="img-skinthumb shadow" src="'.$url.
'" alt="'.
dol_escape_htmltag($title).
'" title="'.
dol_escape_htmltag($title).
'" style="border: none; margin-bottom: 5px;">';
464 if ($subdir == $selected_theme) {
465 print
'<input '.($edit ?
'' :
'disabled').
' type="radio" class="themethumbs" style="border: 0px;" id="main_theme'.$subdir.
'" checked name="main_theme" value="'.$subdir.
'"><label for="main_theme'.$subdir.
'"> <b>'.$subdir.
'</b></label>';
467 print
'<input '.($edit ?
'' :
'disabled').
' type="radio" class="themethumbs" style="border: 0px;" id="main_theme'.$subdir.
'" name="main_theme" value="'.$subdir.
'"><label for="main_theme'.$subdir.
'"> '.$subdir.
'</label>';
478 print
'</div></td></tr></table>';
483 $colorbackhmenu1 =
'';
484 $colorbackvmenu1 =
'';
485 $colortexttitlenotab =
'';
486 $colortexttitlelink =
'';
487 $colorbacktitle1 =
'';
488 $colortexttitle =
'';
489 $colorbacklineimpair1 =
'';
490 $colorbacklineimpair2 =
'';
491 $colorbacklinepair1 =
'';
492 $colorbacklinepair2 =
'';
494 $colorbacklinepairhover =
'';
495 $colorbacklinepairchecked =
'';
499 if (file_exists(DOL_DOCUMENT_ROOT.
'/theme/'.$conf->theme.
'/theme_vars.inc.php')) {
500 include DOL_DOCUMENT_ROOT.
'/theme/'.$conf->theme.
'/theme_vars.inc.php';
504 if ($foruserprofile) {
507 $listofdarkmodes = array(
508 $langs->trans(
"AlwaysDisabled"),
509 $langs->trans(
"AccordingToBrowser"),
510 $langs->trans(
"AlwaysEnabled")
512 print
'<tr class="oddeven">';
513 print
'<td>'.$langs->trans(
"DarkThemeMode").
'</td>';
514 print
'<td colspan="'.($colspan - 1).
'">';
516 print $form->selectarray(
'THEME_DARKMODEENABLED', $listofdarkmodes,
getDolGlobalInt(
'THEME_DARKMODEENABLED'));
520 print $form->textwithpicto(
'', $langs->trans(
"DoesNotWorkWithAllThemes"));
526 if ($foruserprofile) {
548 $listoftopmenumodes = array(
549 $langs->transnoentitiesnoconv(
"IconAndText"),
550 $langs->transnoentitiesnoconv(
"TextOnly"),
551 $langs->transnoentitiesnoconv(
"IconOnlyAllTextsOnHover"),
552 $langs->transnoentitiesnoconv(
"IconOnlyTextOnHover"),
553 $langs->transnoentitiesnoconv(
"IconOnly"),
555 print
'<tr class="oddeven">';
556 print
'<td>'.$langs->trans(
"TopMenuDisableImages").
'</td>';
557 print
'<td colspan="'.($colspan - 1).
'">';
560 print $form->selectarray(
'THEME_TOPMENU_DISABLE_IMAGE', $listoftopmenumodes, isset($conf->global->THEME_TOPMENU_DISABLE_IMAGE) ? $conf->global->THEME_TOPMENU_DISABLE_IMAGE : 0, 0, 0, 0,
'', 0, 0, 0,
'',
'widthcentpercentminusx maxwidth500');
562 print $listoftopmenumodes[
getDolGlobalInt(
'THEME_TOPMENU_DISABLE_IMAGE')];
565 print $form->textwithpicto(
'', $langs->trans(
"NotSupportedByAllThemes"));
571 if ($foruserprofile) {
575 print
'<tr class="oddeven"><td class="titlefieldmiddle">'.$langs->trans(
"EnableShowLogo").
'</td>';
576 print
'<td colspan="'.($colspan - 1).
'" class="valignmiddle">';
578 print ajax_constantonoff(
'MAIN_SHOW_LOGO', array(),
null, 0, 0, 1);
583 print $form->textwithpicto(
'', $langs->trans(
"NotSupportedByAllThemes"), 1,
'help',
'inline-block');
589 if ($foruserprofile) {
593 print
'<tr class="oddeven"><td class="titlefieldmiddle">'.$langs->trans(
"THEME_MENU_COLORLOGO").
'</td>';
594 print
'<td colspan="'.($colspan - 1).
'" class="valignmiddle">';
596 print ajax_constantonoff(
'THEME_MENU_COLORLOGO', array(),
null, 0, 0, 1);
600 print $form->textwithpicto(
'', $langs->trans(
"NotSupportedByAllThemes"), 1,
'help',
'inline-block');
606 if ($foruserprofile) {
608 print
'<tr class="oddeven">';
609 print
'<td>'.$langs->trans(
"UseBorderOnTable").
'</td>';
610 print
'<td colspan="'.($colspan - 1).
'" class="valignmiddle">';
612 print ajax_constantonoff(
'THEME_ELDY_USEBORDERONTABLE', array(),
null, 0, 0, 1);
617 print $form->textwithpicto(
'', $langs->trans(
"NotSupportedByAllThemes"), 1,
'help',
'inline-block');
646 if ($foruserprofile) {
670 print
'<tr class="oddeven">';
671 print
'<td>'.$langs->trans(
"TopMenuBackgroundColor").
'</td>';
672 print
'<td colspan="'.($colspan - 1).
'">';
674 print $formother->selectColor(
colorArrayToHex(
colorStringToArray((
getDolGlobalString(
'THEME_ELDY_TOPMENU_BACK1') ? $conf->global->THEME_ELDY_TOPMENU_BACK1 :
''), array()),
''),
'THEME_ELDY_TOPMENU_BACK1',
'', 1, array(),
'',
'colorbackhmenu1', $default).
' ';
678 print
'<input type="text" class="colorthumb" disabled="disabled" style="padding: 1px; margin-top: 0; margin-bottom: 0; background-color: #'.$color.
'" value="'.$color.
'">';
680 print $langs->trans(
"Default");
683 print
' <span class="nowraponall opacitymedium">'.$langs->trans(
"Default").
'</span>: <strong>'.$default.
'</strong> ';
684 print $form->textwithpicto(
'', $langs->trans(
"NotSupportedByAllThemes").
', '.$langs->trans(
"PressF5AfterChangingThis"));
690 if ($foruserprofile) {
714 print
'<tr class="oddeven">';
715 print
'<td>'.$langs->trans(
"LeftMenuBackgroundColor").
'</td>';
716 print
'<td colspan="'.($colspan - 1).
'">';
718 print $formother->selectColor(
colorArrayToHex(
colorStringToArray((
getDolGlobalString(
'THEME_ELDY_VERMENU_BACK1') ? $conf->global->THEME_ELDY_VERMENU_BACK1 :
''), array()),
''),
'THEME_ELDY_VERMENU_BACK1',
'', 1, array(),
'',
'colorbackvmenu1', $default).
' ';
722 print
'<input type="text" class="colorthumb" disabled="disabled" style="padding: 1px; margin-top: 0; margin-bottom: 0; background-color: #'.$color.
'" value="'.$color.
'">';
724 print $langs->trans(
"Default");
727 print
' <span class="nowraponall opacitymedium">'.$langs->trans(
"Default").
'</span>: <strong>'.$default.
'</strong> ';
728 print $form->textwithpicto(
'', $langs->trans(
"NotSupportedByAllThemes").
', '.$langs->trans(
"PressF5AfterChangingThis"));
734 if ($foruserprofile) {
754 print
'<tr class="oddeven">';
755 print
'<td>'.$langs->trans(
"BackgroundColor").
'</td>';
756 print
'<td colspan="'.($colspan - 1).
'">';
763 print
'<input type="text" class="colorthumb" disabled="disabled" style="padding: 1px; margin-top: 0; margin-bottom: 0; background-color: #'.$color.
'" value="'.$color.
'">';
765 print $langs->trans(
"Default");
768 print
' <span class="nowraponall opacitymedium">'.$langs->trans(
"Default").
'</span>: <strong>'.$default.
'</strong> ';
769 print $form->textwithpicto(
'', $langs->trans(
"NotSupportedByAllThemes").
', '.$langs->trans(
"PressF5AfterChangingThis"));
775 if ($foruserprofile) {
779 print
'<tr class="oddeven">';
780 print
'<td>'.$langs->trans(
"TextTitleColor").
'</td>';
781 print
'<td colspan="'.($colspan - 1).
'">';
783 print $formother->selectColor(
colorArrayToHex(
colorStringToArray((
getDolGlobalString(
'THEME_ELDY_TEXTTITLENOTAB') ? $conf->global->THEME_ELDY_TEXTTITLENOTAB :
''), array()),
''),
'THEME_ELDY_TEXTTITLENOTAB',
'', 1, array(),
'',
'colortexttitlenotab', $default).
' ';
785 print $formother->showColor($conf->global->THEME_ELDY_TEXTTITLENOTAB, $langs->trans(
"Default"));
787 print
' <span class="nowraponall opacitymedium">'.$langs->trans(
"Default").
'</span>: <strong><span style="color: #'.$default.
'">'.$default.
'</span></strong> ';
788 print $form->textwithpicto(
'', $langs->trans(
"NotSupportedByAllThemes").
', '.$langs->trans(
"PressF5AfterChangingThis"));
795 if ($foruserprofile) {
799 print
'<tr class="oddeven">';
800 print
'<td>'.$langs->trans(
"BackgroundTableTitleColor").
'</td>';
801 print
'<td colspan="'.($colspan - 1).
'">';
805 print $formother->showColor($conf->global->THEME_ELDY_BACKTITLE1, $langs->trans(
"Default"));
807 print
' <span class="nowraponall opacitymedium">'.$langs->trans(
"Default").
'</span>: <strong>'.$default.
'</strong> ';
808 print $form->textwithpicto(
'', $langs->trans(
"NotSupportedByAllThemes").
', '.$langs->trans(
"PressF5AfterChangingThis"));
815 if ($foruserprofile) {
819 print
'<tr class="oddeven">';
820 print
'<td>'.$langs->trans(
"BackgroundTableTitleTextColor").
'</td>';
821 print
'<td colspan="'.($colspan - 1).
'">';
825 print $formother->showColor($conf->global->THEME_ELDY_TEXTTITLE, $langs->trans(
"Default"));
827 print
' <span class="nowraponall opacitymedium">'.$langs->trans(
"Default").
'</span>: <strong><span style="color: #'.$default.
'">'.$default.
'</span></strong> ';
828 print $form->textwithpicto(
'', $langs->trans(
"NotSupportedByAllThemes").
', '.$langs->trans(
"PressF5AfterChangingThis"));
835 if ($foruserprofile) {
839 print
'<tr class="oddeven">';
840 print
'<td>'.$langs->trans(
"BackgroundTableTitleTextlinkColor").
'</td>';
841 print
'<td colspan="'.($colspan - 1).
'">';
843 print $formother->selectColor(
colorArrayToHex(
colorStringToArray((
getDolGlobalString(
'THEME_ELDY_TEXTTITLELINK') ? $conf->global->THEME_ELDY_TEXTTITLELINK :
''), array()),
''),
'THEME_ELDY_TEXTTITLELINK',
'', 1, array(),
'',
'colortexttitlelink', $default).
' ';
845 print $formother->showColor($conf->global->THEME_ELDY_TEXTTITLELINK, $langs->trans(
"Default"));
847 print
' <span class="nowraponall opacitymedium">'.$langs->trans(
"Default").
'</span>: <strong><span style="color: #'.$default.
'">'.$default.
'</span></strong> ';
848 print $form->textwithpicto(
'', $langs->trans(
"NotSupportedByAllThemes").
', '.$langs->trans(
"PressF5AfterChangingThis"));
856 if ($foruserprofile) {
860 print
'<tr class="oddeven">';
861 print
'<td>'.$langs->trans(
"BackgroundTableLineOddColor").
'</td>';
862 print
'<td colspan="'.($colspan - 1).
'">';
864 print $formother->selectColor(
colorArrayToHex(
colorStringToArray((
getDolGlobalString(
'THEME_ELDY_LINEIMPAIR1') ? $conf->global->THEME_ELDY_LINEIMPAIR1 :
''), array()),
''),
'THEME_ELDY_LINEIMPAIR1',
'', 1, array(),
'',
'colorbacklineimpair2', $default).
' ';
868 print
'<input type="text" class="colorthumb" disabled="disabled" style="padding: 1px; margin-top: 0; margin-bottom: 0; background-color: #'.$color.
'" value="'.$color.
'">';
870 print $langs->trans(
"Default");
873 print
' <span class="nowraponall opacitymedium">'.$langs->trans(
"Default").
'</span>: <strong>'.$default.
'</strong> ';
874 print $form->textwithpicto(
'', $langs->trans(
"NotSupportedByAllThemes").
', '.$langs->trans(
"PressF5AfterChangingThis"));
880 if ($foruserprofile) {
884 print
'<tr class="oddeven">';
885 print
'<td>'.$langs->trans(
"BackgroundTableLineEvenColor").
'</td>';
886 print
'<td colspan="'.($colspan - 1).
'">';
892 print
'<input type="text" class="colorthumb" disabled="disabled" style="padding: 1px; margin-top: 0; margin-bottom: 0; background-color: #'.$color.
'" value="'.$color.
'">';
894 print $langs->trans(
"Default");
897 print
' <span class="nowraponall opacitymedium">'.$langs->trans(
"Default").
'</span>: <strong>'.$default.
'</strong> ';
898 print $form->textwithpicto(
'', $langs->trans(
"NotSupportedByAllThemes").
', '.$langs->trans(
"PressF5AfterChangingThis"));
904 if ($foruserprofile) {
928 print
'<tr class="oddeven">';
929 print
'<td>'.$langs->trans(
"LinkColor").
'</td>';
930 print
'<td colspan="'.($colspan - 1).
'">';
936 print
'<input type="text" class="colorthumb" disabled="disabled" style="padding: 1px; margin-top: 0; margin-bottom: 0; background-color: #'.$color.
'" value="'.$color.
'">';
940 print $langs->trans(
"Default");
943 print
' <span class="nowraponall opacitymedium">'.$langs->trans(
"Default").
'</span>: <strong><span style="color: #'.$default.
'">'.$default.
'</span></strong> ';
944 print $form->textwithpicto(
'', $langs->trans(
"NotSupportedByAllThemes").
', '.$langs->trans(
"PressF5AfterChangingThis"));
950 if ($foruserprofile) {
964 print
'<tr class="oddeven">';
965 print
'<td>'.$langs->trans(
"HighlightLinesColor").
'</td>';
966 print
'<td colspan="'.($colspan - 1).
'">';
975 print $formother->selectColor($color,
'THEME_ELDY_USE_HOVER',
'', 1, array(),
'',
'colorbacklinepairhover', $default).
' ';
984 print
'<input type="text" class="colorthumb" disabled="disabled" style="padding: 1px; margin-top: 0; margin-bottom: 0; background-color: #'.$color.
'" value="'.$color.
'">';
986 print $langs->trans(
"Default");
989 print $langs->trans(
"Default");
992 print
' <span class="nowraponall opacitymedium">'.$langs->trans(
"Default").
'</span>: <strong>'.$default.
'</strong> ';
993 print $form->textwithpicto(
'', $langs->trans(
"NotSupportedByAllThemes").
', '.$langs->trans(
"PressF5AfterChangingThis"));
998 if ($foruserprofile) {
1012 print
'<tr class="oddeven">';
1013 print
'<td>'.$langs->trans(
"HighlightLinesChecked").
'</td>';
1014 print
'<td colspan="'.($colspan - 1).
'">';
1023 print $formother->selectColor($color,
'THEME_ELDY_USE_CHECKED',
'', 1, array(),
'',
'colorbacklinepairchecked', $default).
' ';
1031 if ($color !=
'e6edf0') {
1032 print
'<input type="text" class="colorthumb" disabled="disabled" style="padding: 1px; margin-top: 0; margin-bottom: 0; background-color: #'.$color.
'" value="'.$color.
'">';
1034 print $langs->trans(
"Default");
1037 print $langs->trans(
"Default");
1040 print
' <span class="nowraponall opacitymedium">'.$langs->trans(
"Default").
'</span>: <strong>'.$default.
'</strong> ';
1041 print $form->textwithpicto(
'', $langs->trans(
"NotSupportedByAllThemes").
', '.$langs->trans(
"PressF5AfterChangingThis"));
1047 if ($foruserprofile) {
1071 print
'<tr class="oddeven">';
1072 print
'<td>'.$langs->trans(
"BtnActionColor").
'</td>';
1073 print
'<td colspan="'.($colspan - 1).
'">';
1079 print
'<input type="text" class="colorthumb" disabled="disabled" style="padding: 1px; margin-top: 0; margin-bottom: 0; background-color: #'.$color.
'" value="'.$color.
'">';
1083 print $langs->trans(
"Default");
1086 print
' <span class="nowraponall opacitymedium">'.$langs->trans(
"Default").
'</span>: <strong><span style="color: #'.$default.
'">'.$default.
'</span></strong> ';
1087 print $form->textwithpicto(
'', $langs->trans(
"NotSupportedByAllThemes").
', '.$langs->trans(
"PressF5AfterChangingThis"));
1093 if ($foruserprofile) {
1117 print
'<tr class="oddeven">';
1118 print
'<td>'.$langs->trans(
"TextBtnActionColor").
'</td>';
1119 print
'<td colspan="'.($colspan - 1).
'">';
1121 print $formother->selectColor(
colorArrayToHex(
colorStringToArray((
getDolGlobalString(
'THEME_ELDY_TEXTBTNACTION') ? $conf->global->THEME_ELDY_TEXTBTNACTION :
''), array()),
''),
'THEME_ELDY_TEXTBTNACTION',
'', 1, array(),
'',
'textbutaction', $default).
' ';
1125 print
'<input type="text" class="colorthumb" disabled="disabled" style="padding: 1px; margin-top: 0; margin-bottom: 0; background-color: #'.$color.
'" value="'.$color.
'">';
1129 print $langs->trans(
"Default");
1132 print
' <span class="nowraponall opacitymedium">'.$langs->trans(
"Default").
'</span>: <strong><span style="color: #000">'.$default.
'</span></strong> ';
1133 print $form->textwithpicto(
'', $langs->trans(
"NotSupportedByAllThemes").
', '.$langs->trans(
"PressF5AfterChangingThis"));
1139 if ($foruserprofile) {
1141 $default = $langs->trans(
'No');
1142 print
'<tr class="oddeven">';
1143 print
'<td>'.$langs->trans(
"MAIN_OPTIMIZEFORTEXTBROWSER").
'</td>';
1144 print
'<td colspan="'.($colspan - 1).
'">';
1147 print $form->selectyesno(
'MAIN_OPTIMIZEFORTEXTBROWSER', (isset($fuser->conf->MAIN_OPTIMIZEFORTEXTBROWSER) ? $fuser->conf->MAIN_OPTIMIZEFORTEXTBROWSER : 0), 1);
1150 print
yn(isset($fuser->conf->MAIN_OPTIMIZEFORTEXTBROWSER) ? $fuser->conf->MAIN_OPTIMIZEFORTEXTBROWSER : 0);
1153 if (empty($fuser->conf->MAIN_OPTIMIZEFORTEXTBROWSER)) {
1154 print
' ('.$langs->trans(
"ForcedByGlobalSetup").
')';
1158 print
' <span class="opacitymedium">'.$langs->trans(
"Default").
'</span>: <strong>'.$default.
'</strong> ';
1159 print $form->textwithpicto(
'', $langs->trans(
"MAIN_OPTIMIZEFORTEXTBROWSERDesc"));
1184 if ($foruserprofile) {
1186 $default = $langs->trans(
'No');
1187 print
'<tr class="oddeven">';
1188 print
'<td>'.$langs->trans(
"MAIN_OPTIMIZEFORCOLORBLIND").
'</td>';
1189 print
'<td colspan="'.($colspan - 1).
'">';
1191 $colorBlindOptions = array(
1192 0 => $langs->trans(
'No'),
1193 'flashy' => $langs->trans(
'Flashy'),
1194 'protanopia' => $langs->trans(
'Protanopia'),
1195 'deuteranopes' => $langs->trans(
'Deuteranopes'),
1196 'tritanopes' => $langs->trans(
'Tritanopes'),
1200 print $form->selectArray(
'MAIN_OPTIMIZEFORCOLORBLIND', $colorBlindOptions, (isset($fuser->conf->MAIN_OPTIMIZEFORCOLORBLIND) ? $fuser->conf->MAIN_OPTIMIZEFORCOLORBLIND : 0), 0);
1202 if (!empty($fuser->conf->MAIN_OPTIMIZEFORCOLORBLIND) && isset($colorBlindOptions[$fuser->conf->MAIN_OPTIMIZEFORCOLORBLIND])) {
1203 print $colorBlindOptions[$fuser->conf->MAIN_OPTIMIZEFORCOLORBLIND];
1208 print
' <span class="opacitymedium">'.$langs->trans(
"Default").
'</span>: <strong>'.$default.
'</strong> ';
1209 print $form->textwithpicto(
'', $langs->trans(
"MAIN_OPTIMIZEFORCOLORBLINDDesc"));