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";
116 $sql .=
" FROM ".MAIN_DB_PREFIX.
"notify_def as n, ".MAIN_DB_PREFIX.
"c_action_trigger as a";
117 $sql .=
" WHERE fk_user = ".((int)
$object->id);
118 $sql .=
" AND a.rowid = n.fk_action AND n.fk_user = ".((int)
$object->id);
119 $sql .=
" AND entity IN (".getEntity(
'notify_def').
')';
121 $resql = $db->query($sql);
123 $num = $db->num_rows($resql);
126 $obj = $db->fetch_object($resql);
134 $langs->load(
"mails");
135 $head[$h][0] = DOL_URL_ROOT.
'/user/notify/card.php?id='.
$object->id;
136 $head[$h][1] = $langs->trans(
"NotificationsAuto");
138 $head[$h][1] .=
'<span class="badge marginleftonlyshort">'.$nbNote.
'</span>';
140 $head[$h][2] =
'notify';
150 if ((isModEnabled(
'salaries') && $user->hasRight(
'salaries',
'read'))
151 || (isModEnabled(
'hrm') && $user->hasRight(
'hrm',
'employee',
'read'))
152 || (isModEnabled(
'expensereport') && $user->hasRight(
'expensereport',
'lire') && ($user->id ==
$object->id || $user->hasRight(
'expensereport',
'readall')))
153 || (isModEnabled(
'holiday') && $user->hasRight(
'holiday',
'read') && ($user->id ==
$object->id || $user->hasRight(
'holiday',
'readall')))
156 $head[$h][0] = DOL_URL_ROOT.
'/user/bank.php?id='.
$object->id;
157 $head[$h][1] = $langs->trans(
"HRAndBank");
158 $head[$h][2] =
'bank';
163 if (empty($user->socid)) {
166 if (!empty(
$object->note_public)) {
169 if (!empty(
$object->note_private)) {
172 $head[$h][0] = DOL_URL_ROOT.
'/user/note.php?id='.
$object->id;
173 $head[$h][1] = $langs->trans(
"Note");
175 $head[$h][1] .=
'<span class="badge marginleftonlyshort">'.$nbNote.
'</span>';
177 $head[$h][2] =
'note';
181 require_once DOL_DOCUMENT_ROOT.
'/core/lib/files.lib.php';
182 require_once DOL_DOCUMENT_ROOT.
'/core/class/link.class.php';
184 $nbFiles = count(
dol_dir_list($upload_dir,
'files', 0,
'',
'(\.meta|_preview.*\.png)$'));
186 $head[$h][0] = DOL_URL_ROOT.
'/user/document.php?userid='.
$object->id;
187 $head[$h][1] = $langs->trans(
"Documents");
188 if (($nbFiles + $nbLinks) > 0) {
189 $head[$h][1] .=
'<span class="badge marginleftonlyshort">'.($nbFiles + $nbLinks).
'</span>';
191 $head[$h][2] =
'document';
194 $head[$h][0] = DOL_URL_ROOT.
'/user/agenda.php?id='.
$object->id;
195 $head[$h][1] = $langs->trans(
"Events");
196 if (isModEnabled(
'agenda') && ($user->hasRight(
'agenda',
'myactions',
'read') || $user->hasRight(
'agenda',
'allactions',
'read'))) {
199 require_once DOL_DOCUMENT_ROOT.
'/core/lib/memory.lib.php';
200 $cachekey =
'count_events_user_'.$object->id;
202 if (!is_null($dataretrieved)) {
203 $nbEvent = $dataretrieved;
205 $sql =
"SELECT COUNT(ac.id) as nb";
206 $sql .=
" FROM ".MAIN_DB_PREFIX.
"actioncomm as ac";
207 $sql .=
" WHERE ac.fk_user_action = ".((int)
$object->id);
208 $sql .=
" AND ac.entity IN (".getEntity(
'agenda').
")";
209 $resql = $db->query($sql);
211 $obj = $db->fetch_object($resql);
214 dol_syslog(
'Failed to count actioncomm '.$db->lasterror(), LOG_ERR);
220 $head[$h][1] .= $langs->trans(
"Agenda");
222 $head[$h][1] .=
'<span class="badge marginleftonlyshort">'.$nbEvent.
'</span>';
225 $head[$h][2] =
'info';
348function showSkins($fuser, $edit = 0, $foruserprofile =
false)
350 global
$conf, $langs, $db, $form;
352 require_once DOL_DOCUMENT_ROOT.
'/core/class/html.formother.class.php';
356 $dirthemes = array(
'/theme');
357 if (!empty(
$conf->modules_parts[
'theme'])) {
358 foreach (
$conf->modules_parts[
'theme'] as $reldir) {
359 $dirthemes = array_merge($dirthemes, (array) ($reldir.
'theme'));
362 $dirthemes = array_unique($dirthemes);
365 $selected_theme =
'';
366 if (empty($foruserprofile)) {
369 $selected_theme = ((is_object($fuser) && !empty($fuser->conf->MAIN_THEME)) ? $fuser->conf->MAIN_THEME :
'');
373 if (empty($foruserprofile)) {
376 $hoverdisabled = (is_object($fuser) ? (empty($fuser->conf->THEME_ELDY_USE_HOVER) || $fuser->conf->THEME_ELDY_USE_HOVER ==
'0') :
'');
379 $checkeddisabled =
'';
380 if (empty($foruserprofile)) {
383 $checkeddisabled = (is_object($fuser) ? (empty($fuser->conf->THEME_ELDY_USE_CHECKED) || $fuser->conf->THEME_ELDY_USE_CHECKED ==
'0') :
'');
387 if ($foruserprofile) {
392 print
'<div class="div-table-responsive-no-min">';
393 print
'<table class="noborder centpercent'.($edit ?
' editmodeforshowskin' :
'').
'">';
396 if ($foruserprofile) {
397 print
'<tr class="liste_titre"><th class="titlefieldmiddle">'.$langs->trans(
"Parameter").
'</th><th>'.$langs->trans(
"DefaultValue").
'</th>';
398 print
'<th colspan="2"> </th>';
402 print
'<td>'.$langs->trans(
"DefaultSkin").
'</td>';
404 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>';
405 print
'<td> </td>';
408 $dirthemestring =
'';
409 foreach ($dirthemes as $dirtheme) {
410 $dirthemestring .=
'"'.$dirtheme.
'" ';
413 print
'<tr class="liste_titre"><th class="titlefieldmiddle">';
414 print $form->textwithpicto($langs->trans(
"DefaultSkin"), $langs->trans(
"ThemeDir").
' : '.$dirthemestring);
416 print
'<th class="right">';
417 $url =
'https://www.dolistore.com/9-skins';
418 print
'<a href="'.$url.
'" target="_blank" rel="noopener noreferrer external">';
419 print $langs->trans(
'DownloadMoreSkins');
420 print
img_picto(
'',
'globe',
'class="paddingleft"');
425 print
'<tr><td colspan="'.$colspan.
'" class="center">';
428 $langs->load(
"errors");
432 print
'<table class="nobordernopadding centpercent"><tr><td><div class="center">';
435 foreach ($dirthemes as $dir) {
440 if (is_dir($dirtheme)) {
441 $handle = opendir($dirtheme);
442 if (is_resource($handle)) {
443 while (($subdir = readdir($handle)) !==
false) {
444 if (is_dir($dirtheme.
"/".$subdir) && substr($subdir, 0, 1) !=
'.'
445 && substr($subdir, 0, 3) !=
'CVS' && !preg_match(
'/common|phones/i', $subdir)) {
447 if (
getDolGlobalInt(
'MAIN_FEATURES_LEVEL') < 2 && preg_match(
'/_dev$/i', $subdir)) {
450 if (
getDolGlobalInt(
'MAIN_FEATURES_LEVEL') < 1 && preg_match(
'/_exp$/i', $subdir)) {
454 print
'<div class="inline-block" style="margin-top: 10px; margin-bottom: 10px; margin-right: 20px; margin-left: 20px;">';
455 $file = $dirtheme.
"/".$subdir.
"/thumb.png";
456 $url = $urltheme.
"/".$subdir.
"/thumb.png";
457 if (!file_exists($file)) {
458 $url = DOL_URL_ROOT.
'/public/theme/common/nophoto.png';
460 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").
'">';
461 if ($subdir ==
$conf->global->MAIN_THEME) {
462 $title = $langs->trans(
"ThemeCurrentlyActive");
464 $title = $langs->trans(
"ShowPreview");
466 print
'<img class="img-skinthumb shadow" src="'.$url.
'" alt="'.
dol_escape_htmltag($title).
'" title="'.
dol_escape_htmltag($title).
'" style="border: none; margin-bottom: 5px;">';
468 if ($subdir == $selected_theme) {
469 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>';
471 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>';
482 print
'</div></td></tr></table>';
487 $colorbackhmenu1 =
'';
488 $colorbackvmenu1 =
'';
489 $colortexttitlenotab =
'';
490 $colortexttitlelink =
'';
491 $colorbacktitle1 =
'';
492 $colortexttitle =
'';
493 $colorbacklineimpair1 =
'';
494 $colorbacklineimpair2 =
'';
495 $colorbacklinepair1 =
'';
496 $colorbacklinepair2 =
'';
498 $colorbacklinepairhover =
'';
499 $colorbacklinepairchecked =
'';
503 if (file_exists(DOL_DOCUMENT_ROOT.
'/theme/'.
$conf->theme.
'/theme_vars.inc.php')) {
504 include DOL_DOCUMENT_ROOT.
'/theme/'.
$conf->theme.
'/theme_vars.inc.php';
508 if ($foruserprofile) {
511 $listofdarkmodes = array(
512 $langs->trans(
"AlwaysDisabled"),
513 $langs->trans(
"AccordingToBrowser"),
514 $langs->trans(
"AlwaysEnabled")
516 print
'<tr class="oddeven">';
517 print
'<td>'.$langs->trans(
"DarkThemeMode").
'</td>';
518 print
'<td colspan="'.($colspan - 1).
'">';
520 print $form->selectarray(
'THEME_DARKMODEENABLED', $listofdarkmodes,
getDolGlobalInt(
'THEME_DARKMODEENABLED'));
524 print $form->textwithpicto(
'', $langs->trans(
"DoesNotWorkWithAllThemes"));
530 if ($foruserprofile) {
552 $listoftopmenumodes = array(
553 $langs->transnoentitiesnoconv(
"IconAndText"),
554 $langs->transnoentitiesnoconv(
"TextOnly"),
555 $langs->transnoentitiesnoconv(
"IconOnlyAllTextsOnHover"),
556 $langs->transnoentitiesnoconv(
"IconOnlyTextOnHover"),
557 $langs->transnoentitiesnoconv(
"IconOnly"),
559 print
'<tr class="oddeven">';
560 print
'<td>'.$langs->trans(
"TopMenuDisableImages").
'</td>';
561 print
'<td colspan="'.($colspan - 1).
'">';
563 print $form->selectarray(
'THEME_TOPMENU_DISABLE_IMAGE', $listoftopmenumodes,
getDolGlobalInt(
'THEME_TOPMENU_DISABLE_IMAGE'), 0, 0, 0,
'', 0, 0, 0,
'',
'widthcentpercentminusx maxwidth500');
565 print $listoftopmenumodes[
getDolGlobalInt(
'THEME_TOPMENU_DISABLE_IMAGE')];
567 print $form->textwithpicto(
'', $langs->trans(
"NotSupportedByAllThemes"));
573 if ($foruserprofile) {
577 print
'<tr class="oddeven"><td class="titlefieldmiddle">'.$langs->trans(
"EnableShowLogo").
'</td>';
578 print
'<td colspan="'.($colspan - 1).
'" class="valignmiddle">';
580 print ajax_constantonoff(
'MAIN_SHOW_LOGO', array(),
null, 0, 0, 1);
585 print $form->textwithpicto(
'', $langs->trans(
"NotSupportedByAllThemes"), 1,
'help',
'inline-block');
591 if ($foruserprofile) {
595 print
'<tr class="oddeven"><td class="titlefieldmiddle">'.$langs->trans(
"THEME_MENU_COLORLOGO").
'</td>';
596 print
'<td colspan="'.($colspan - 1).
'" class="valignmiddle">';
598 print ajax_constantonoff(
'THEME_MENU_COLORLOGO', array(),
null, 0, 0, 1);
602 print $form->textwithpicto(
'', $langs->trans(
"NotSupportedByAllThemes"), 1,
'help',
'inline-block');
608 if ($foruserprofile) {
610 print
'<tr class="oddeven">';
611 print
'<td>'.$langs->trans(
"UseBorderOnTable").
'</td>';
612 print
'<td colspan="'.($colspan - 1).
'" class="valignmiddle">';
614 print ajax_constantonoff(
'THEME_ELDY_USEBORDERONTABLE', array(),
null, 0, 0, 1, 2, 0, 1);
618 print $form->textwithpicto(
'', $langs->trans(
"NotSupportedByAllThemes"), 1,
'help',
'inline-block');
623 if ($foruserprofile) {
626 $listofborderradius = array(
627 0 => $langs->transnoentitiesnoconv(
"No"),
628 4 => $langs->transnoentitiesnoconv(
"Size").
' 4',
629 6 => $langs->transnoentitiesnoconv(
"Size").
' 6',
630 8 => $langs->transnoentitiesnoconv(
"Size").
' 8',
631 10 => $langs->transnoentitiesnoconv(
"Size").
' 10',
632 20 => $langs->transnoentitiesnoconv(
"Size").
' 20',
635 print
'<tr class="oddeven">';
636 print
'<td>'.$langs->trans(
"RoundBorders").
'</td>';
637 print
'<td colspan="'.($colspan - 1).
'" class="valignmiddle">';
639 print $form->selectarray(
'THEME_ELDY_BORDER_RADIUS', $listofborderradius,
getDolGlobalInt(
'THEME_ELDY_BORDER_RADIUS'), 0, 0, 0,
'', 0, 0, 0,
'',
'widthcentpercentminusx maxwidth100');
641 print $listofborderradius[
getDolGlobalInt(
'THEME_ELDY_BORDER_RADIUS')];
643 print $form->textwithpicto(
'', $langs->trans(
"NotSupportedByAllThemes"), 1,
'help',
'inline-block');
672 if ($foruserprofile) {
696 print
'<tr class="oddeven">';
697 print
'<td>'.$langs->trans(
"TopMenuBackgroundColor").
'</td>';
698 print
'<td colspan="'.($colspan - 1).
'">';
704 print
'<input type="text" class="colorthumb" disabled="disabled" style="padding: 1px; margin-top: 0; margin-bottom: 0; background-color: #'.$color.
'" value="'.$color.
'">';
706 print $langs->trans(
"Default");
709 print
' <span class="nowraponall opacitymedium">'.$langs->trans(
"Default").
'</span>: <strong>'.$default.
'</strong> ';
710 print $form->textwithpicto(
'', $langs->trans(
"NotSupportedByAllThemes").
', '.$langs->trans(
"PressF5AfterChangingThis"));
716 if ($foruserprofile) {
740 print
'<tr class="oddeven">';
741 print
'<td>'.$langs->trans(
"LeftMenuBackgroundColor").
'</td>';
742 print
'<td colspan="'.($colspan - 1).
'">';
748 print
'<input type="text" class="colorthumb" disabled="disabled" style="padding: 1px; margin-top: 0; margin-bottom: 0; background-color: #'.$color.
'" value="'.$color.
'">';
750 print $langs->trans(
"Default");
753 print
' <span class="nowraponall opacitymedium">'.$langs->trans(
"Default").
'</span>: <strong>'.$default.
'</strong> ';
754 print $form->textwithpicto(
'', $langs->trans(
"NotSupportedByAllThemes").
', '.$langs->trans(
"PressF5AfterChangingThis"));
760 if ($foruserprofile) {
780 print
'<tr class="oddeven">';
781 print
'<td>'.$langs->trans(
"BackgroundColor").
'</td>';
782 print
'<td colspan="'.($colspan - 1).
'">';
789 print
'<input type="text" class="colorthumb" disabled="disabled" style="padding: 1px; margin-top: 0; margin-bottom: 0; background-color: #'.$color.
'" value="'.$color.
'">';
791 print $langs->trans(
"Default");
794 print
' <span class="nowraponall opacitymedium">'.$langs->trans(
"Default").
'</span>: <strong>'.$default.
'</strong> ';
795 print $form->textwithpicto(
'', $langs->trans(
"NotSupportedByAllThemes").
', '.$langs->trans(
"PressF5AfterChangingThis"));
801 if ($foruserprofile) {
805 print
'<tr class="oddeven">';
806 print
'<td>'.$langs->trans(
"TextTitleColor").
'</td>';
807 print
'<td colspan="'.($colspan - 1).
'">';
811 print $formother->showColor(
$conf->global->THEME_ELDY_TEXTTITLENOTAB, $langs->trans(
"Default"));
813 print
' <span class="nowraponall opacitymedium">'.$langs->trans(
"Default").
'</span>: <strong><span style="color: #'.$default.
'">'.$default.
'</span></strong> ';
814 print $form->textwithpicto(
'', $langs->trans(
"NotSupportedByAllThemes").
', '.$langs->trans(
"PressF5AfterChangingThis"));
821 if ($foruserprofile) {
825 print
'<tr class="oddeven">';
826 print
'<td>'.$langs->trans(
"BackgroundTableTitleColor").
'</td>';
827 print
'<td colspan="'.($colspan - 1).
'">';
831 print $formother->showColor(
$conf->global->THEME_ELDY_BACKTITLE1, $langs->trans(
"Default"));
833 print
' <span class="nowraponall opacitymedium">'.$langs->trans(
"Default").
'</span>: <strong>'.$default.
'</strong> ';
834 print $form->textwithpicto(
'', $langs->trans(
"NotSupportedByAllThemes").
', '.$langs->trans(
"PressF5AfterChangingThis"));
841 if ($foruserprofile) {
845 print
'<tr class="oddeven">';
846 print
'<td>'.$langs->trans(
"BackgroundTableTitleTextColor").
'</td>';
847 print
'<td colspan="'.($colspan - 1).
'">';
851 print $formother->showColor(
$conf->global->THEME_ELDY_TEXTTITLE, $langs->trans(
"Default"));
853 print
' <span class="nowraponall opacitymedium">'.$langs->trans(
"Default").
'</span>: <strong><span style="color: #'.$default.
'">'.$default.
'</span></strong> ';
854 print $form->textwithpicto(
'', $langs->trans(
"NotSupportedByAllThemes").
', '.$langs->trans(
"PressF5AfterChangingThis"));
861 if ($foruserprofile) {
865 print
'<tr class="oddeven">';
866 print
'<td>'.$langs->trans(
"BackgroundTableTitleTextlinkColor").
'</td>';
867 print
'<td colspan="'.($colspan - 1).
'">';
871 print $formother->showColor(
$conf->global->THEME_ELDY_TEXTTITLELINK, $langs->trans(
"Default"));
873 print
' <span class="nowraponall opacitymedium">'.$langs->trans(
"Default").
'</span>: <strong><span style="color: #'.$default.
'">'.$default.
'</span></strong> ';
874 print $form->textwithpicto(
'', $langs->trans(
"NotSupportedByAllThemes").
', '.$langs->trans(
"PressF5AfterChangingThis"));
882 if ($foruserprofile) {
886 print
'<tr class="oddeven">';
887 print
'<td>'.$langs->trans(
"BackgroundTableLineOddColor").
'</td>';
888 print
'<td colspan="'.($colspan - 1).
'">';
894 print
'<input type="text" class="colorthumb" disabled="disabled" style="padding: 1px; margin-top: 0; margin-bottom: 0; background-color: #'.$color.
'" value="'.$color.
'">';
896 print $langs->trans(
"Default");
899 print
' <span class="nowraponall opacitymedium">'.$langs->trans(
"Default").
'</span>: <strong>'.$default.
'</strong> ';
900 print $form->textwithpicto(
'', $langs->trans(
"NotSupportedByAllThemes").
', '.$langs->trans(
"PressF5AfterChangingThis"));
906 if ($foruserprofile) {
910 print
'<tr class="oddeven">';
911 print
'<td>'.$langs->trans(
"BackgroundTableLineEvenColor").
'</td>';
912 print
'<td colspan="'.($colspan - 1).
'">';
918 print
'<input type="text" class="colorthumb" disabled="disabled" style="padding: 1px; margin-top: 0; margin-bottom: 0; background-color: #'.$color.
'" value="'.$color.
'">';
920 print $langs->trans(
"Default");
923 print
' <span class="nowraponall opacitymedium">'.$langs->trans(
"Default").
'</span>: <strong>'.$default.
'</strong> ';
924 print $form->textwithpicto(
'', $langs->trans(
"NotSupportedByAllThemes").
', '.$langs->trans(
"PressF5AfterChangingThis"));
930 if ($foruserprofile) {
954 print
'<tr class="oddeven">';
955 print
'<td>'.$langs->trans(
"LinkColor").
'</td>';
956 print
'<td colspan="'.($colspan - 1).
'">';
962 print
'<input type="text" class="colorthumb" disabled="disabled" style="padding: 1px; margin-top: 0; margin-bottom: 0; background-color: #'.$color.
'" value="'.$color.
'">';
966 print $langs->trans(
"Default");
969 print
' <span class="nowraponall opacitymedium">'.$langs->trans(
"Default").
'</span>: <strong><span style="color: #'.$default.
'">'.$default.
'</span></strong> ';
970 print $form->textwithpicto(
'', $langs->trans(
"NotSupportedByAllThemes").
', '.$langs->trans(
"PressF5AfterChangingThis"));
976 if ($foruserprofile) {
990 print
'<tr class="oddeven">';
991 print
'<td>'.$langs->trans(
"HighlightLinesColor").
'</td>';
992 print
'<td colspan="'.($colspan - 1).
'">';
1001 print $formother->selectColor($color,
'THEME_ELDY_USE_HOVER',
'', 1, array(),
'',
'colorbacklinepairhover', $default).
' ';
1010 print
'<input type="text" class="colorthumb" disabled="disabled" style="padding: 1px; margin-top: 0; margin-bottom: 0; background-color: #'.$color.
'" value="'.$color.
'">';
1012 print $langs->trans(
"Default");
1015 print $langs->trans(
"Default");
1018 print
' <span class="nowraponall opacitymedium">'.$langs->trans(
"Default").
'</span>: <strong>'.$default.
'</strong> ';
1019 print $form->textwithpicto(
'', $langs->trans(
"NotSupportedByAllThemes").
', '.$langs->trans(
"PressF5AfterChangingThis"));
1024 if ($foruserprofile) {
1038 print
'<tr class="oddeven">';
1039 print
'<td>'.$langs->trans(
"HighlightLinesChecked").
'</td>';
1040 print
'<td colspan="'.($colspan - 1).
'">';
1049 print $formother->selectColor($color,
'THEME_ELDY_USE_CHECKED',
'', 1, array(),
'',
'colorbacklinepairchecked', $default).
' ';
1057 if ($color !=
'e6edf0') {
1058 print
'<input type="text" class="colorthumb" disabled="disabled" style="padding: 1px; margin-top: 0; margin-bottom: 0; background-color: #'.$color.
'" value="'.$color.
'">';
1060 print $langs->trans(
"Default");
1063 print $langs->trans(
"Default");
1066 print
' <span class="nowraponall opacitymedium">'.$langs->trans(
"Default").
'</span>: <strong>'.$default.
'</strong> ';
1067 print $form->textwithpicto(
'', $langs->trans(
"NotSupportedByAllThemes").
', '.$langs->trans(
"PressF5AfterChangingThis"));
1073 if ($foruserprofile) {
1097 print
'<tr class="oddeven">';
1098 print
'<td>'.$langs->trans(
"BtnActionColor").
'</td>';
1099 print
'<td colspan="'.($colspan - 1).
'">';
1105 print
'<input type="text" class="colorthumb" disabled="disabled" style="padding: 1px; margin-top: 0; margin-bottom: 0; background-color: #'.$color.
'" value="'.$color.
'">';
1109 print $langs->trans(
"Default");
1112 print
' <span class="nowraponall opacitymedium">'.$langs->trans(
"Default").
'</span>: <strong><span style="color: #'.$default.
'">'.$default.
'</span></strong> ';
1113 print $form->textwithpicto(
'', $langs->trans(
"NotSupportedByAllThemes").
', '.$langs->trans(
"PressF5AfterChangingThis"));
1119 if ($foruserprofile) {
1143 print
'<tr class="oddeven">';
1144 print
'<td>'.$langs->trans(
"TextBtnActionColor").
'</td>';
1145 print
'<td colspan="'.($colspan - 1).
'">';
1151 print
'<input type="text" class="colorthumb" disabled="disabled" style="padding: 1px; margin-top: 0; margin-bottom: 0; background-color: #'.$color.
'" value="'.$color.
'">';
1155 print $langs->trans(
"Default");
1158 print
' <span class="nowraponall opacitymedium">'.$langs->trans(
"Default").
'</span>: <strong><span style="color: #000">'.$default.
'</span></strong> ';
1159 print $form->textwithpicto(
'', $langs->trans(
"NotSupportedByAllThemes").
', '.$langs->trans(
"PressF5AfterChangingThis"));
1165 if ($foruserprofile) {
1167 $default = $langs->trans(
'No');
1168 print
'<tr class="oddeven">';
1169 print
'<td>'.$langs->trans(
"MAIN_OPTIMIZEFORTEXTBROWSER").
'</td>';
1170 print
'<td colspan="'.($colspan - 1).
'">';
1173 print $form->selectyesno(
'MAIN_OPTIMIZEFORTEXTBROWSER', (isset($fuser->conf->MAIN_OPTIMIZEFORTEXTBROWSER) ? $fuser->conf->MAIN_OPTIMIZEFORTEXTBROWSER : 0), 1);
1176 print
yn(isset($fuser->conf->MAIN_OPTIMIZEFORTEXTBROWSER) ? $fuser->conf->MAIN_OPTIMIZEFORTEXTBROWSER : 0);
1179 if (empty($fuser->conf->MAIN_OPTIMIZEFORTEXTBROWSER)) {
1180 print
' ('.$langs->trans(
"ForcedByGlobalSetup").
')';
1184 print
' <span class="opacitymedium">'.$langs->trans(
"Default").
'</span>: <strong>'.$default.
'</strong> ';
1185 print $form->textwithpicto(
'', $langs->trans(
"MAIN_OPTIMIZEFORTEXTBROWSERDesc"));
1210 if ($foruserprofile) {
1212 $default = $langs->trans(
'No');
1213 print
'<tr class="oddeven">';
1214 print
'<td>'.$langs->trans(
"MAIN_OPTIMIZEFORCOLORBLIND").
'</td>';
1215 print
'<td colspan="'.($colspan - 1).
'">';
1217 $colorBlindOptions = array(
1218 0 => $langs->trans(
'No'),
1219 'flashy' => $langs->trans(
'Flashy'),
1220 'protanopia' => $langs->trans(
'Protanopia'),
1221 'deuteranopes' => $langs->trans(
'Deuteranopes'),
1222 'tritanopes' => $langs->trans(
'Tritanopes'),
1226 print $form->selectArray(
'MAIN_OPTIMIZEFORCOLORBLIND', $colorBlindOptions, (isset($fuser->conf->MAIN_OPTIMIZEFORCOLORBLIND) ? $fuser->conf->MAIN_OPTIMIZEFORCOLORBLIND : 0), 0);
1228 if (!empty($fuser->conf->MAIN_OPTIMIZEFORCOLORBLIND) && isset($colorBlindOptions[$fuser->conf->MAIN_OPTIMIZEFORCOLORBLIND])) {
1229 print $colorBlindOptions[$fuser->conf->MAIN_OPTIMIZEFORCOLORBLIND];
1234 print
' <span class="opacitymedium">'.$langs->trans(
"Default").
'</span>: <strong>'.$default.
'</strong> ';
1235 print $form->textwithpicto(
'', $langs->trans(
"MAIN_OPTIMIZEFORCOLORBLINDDesc"));