37 global $langs, $conf, $user, $db;
39 $langs->load(
"users");
42 if (!empty($conf->global->MAIN_USE_ADVANCED_PERMS)) {
43 $canreadperms = ($user->admin || ($user->id != $object->id && $user->rights->user->user_advance->readperms) || ($user->id == $object->id && $user->rights->user->self_advance->readperms));
49 $head[$h][0] = DOL_URL_ROOT.
'/user/card.php?id='.$object->id;
50 $head[$h][1] = $langs->trans(
"User");
51 $head[$h][2] =
'user';
54 if ((!empty($conf->ldap->enabled) && !empty($conf->global->LDAP_SYNCHRO_ACTIVE))
55 && (empty($conf->global->MAIN_DISABLE_LDAP_TAB) || !empty($user->admin))) {
57 $head[$h][0] = DOL_URL_ROOT.
'/user/ldap.php?id='.$object->id;
58 $head[$h][1] = $langs->trans(
"LDAPCard");
59 $head[$h][2] =
'ldap';
64 $head[$h][0] = DOL_URL_ROOT.
'/user/perms.php?id='.$object->id;
65 $head[$h][1] = $langs->trans(
"Rights").(empty($conf->global->MAIN_OPTIMIZEFORTEXTBROWSER) ?
'<span class="badge marginleftonlyshort">'.($object->nb_rights).
'</span>' :
'');
66 $head[$h][2] =
'rights';
70 $head[$h][0] = DOL_URL_ROOT.
'/user/param_ihm.php?id='.$object->id;
71 $head[$h][1] = $langs->trans(
"UserGUISetup");
72 $head[$h][2] =
'guisetup';
76 if (empty($conf->global->AGENDA_EXT_NB)) {
77 $conf->global->AGENDA_EXT_NB = 5;
79 $MAXAGENDA = $conf->global->AGENDA_EXT_NB;
83 while ($i <= $MAXAGENDA) {
85 $name =
'AGENDA_EXT_NAME_'.$object->id.
'_'.$key;
86 $src =
'AGENDA_EXT_SRC_'.$object->id.
'_'.$key;
87 $offsettz =
'AGENDA_EXT_OFFSETTZ_'.$object->id.
'_'.$key;
88 $color =
'AGENDA_EXT_COLOR_'.$object->id.
'_'.$key;
91 if (!empty($object->conf->$name)) {
96 $head[$h][0] = DOL_URL_ROOT.
'/user/agenda_extsites.php?id='.$object->id;
97 $head[$h][1] = $langs->trans(
"ExtSites").($nbagenda ?
'<span class="badge marginleftonlyshort">'.$nbagenda.
'</span>' :
'');
98 $head[$h][2] =
'extsites';
102 if (!empty($conf->clicktodial->enabled)) {
103 $head[$h][0] = DOL_URL_ROOT.
'/user/clicktodial.php?id='.$object->id;
104 $head[$h][1] = $langs->trans(
"ClickToDial");
105 $head[$h][2] =
'clicktodial';
110 if ($user->socid == 0 && !empty($conf->notification->enabled)) {
112 $sql =
"SELECT COUNT(n.rowid) as nb";
113 $sql .=
" FROM ".MAIN_DB_PREFIX.
"notify_def as n";
114 $sql .=
" WHERE fk_user = ".((int) $object->id);
115 $resql = $db->query($sql);
117 $num = $db->num_rows(
$resql);
120 $obj = $db->fetch_object(
$resql);
128 $langs->load(
"mails");
129 $head[$h][0] = DOL_URL_ROOT.
'/user/notify/card.php?id='.$object->id;
130 $head[$h][1] = $langs->trans(
"NotificationsAuto");
132 $head[$h][1] .=
'<span class="badge marginleftonlyshort">'.$nbNote.
'</span>';
134 $head[$h][2] =
'notify';
144 if ((!empty($conf->salaries->enabled) && !empty($user->rights->salaries->read))
145 || (!empty($conf->hrm->enabled) && !empty($user->rights->hrm->employee->read))
146 || (!empty($conf->expensereport->enabled) && !empty($user->rights->expensereport->lire) && ($user->id == $object->id || $user->rights->expensereport->readall))
147 || (!empty($conf->holiday->enabled) && !empty($user->rights->holiday->read) && ($user->id == $object->id || $user->rights->holiday->readall))
150 $head[$h][0] = DOL_URL_ROOT.
'/user/bank.php?id='.$object->id;
151 $head[$h][1] = $langs->trans(
"HRAndBank");
152 $head[$h][2] =
'bank';
157 if (empty($user->socid)) {
160 if (!empty($object->note)) {
163 $head[$h][0] = DOL_URL_ROOT.
'/user/note.php?id='.$object->id;
164 $head[$h][1] = $langs->trans(
"Note");
166 $head[$h][1] .=
'<span class="badge marginleftonlyshort">'.$nbNote.
'</span>';
168 $head[$h][2] =
'note';
172 require_once DOL_DOCUMENT_ROOT.
'/core/lib/files.lib.php';
173 require_once DOL_DOCUMENT_ROOT.
'/core/class/link.class.php';
174 $upload_dir = $conf->user->dir_output.
"/".$object->id;
175 $nbFiles = count(
dol_dir_list($upload_dir,
'files', 0,
'',
'(\.meta|_preview.*\.png)$'));
176 $nbLinks =
Link::count($db, $object->element, $object->id);
177 $head[$h][0] = DOL_URL_ROOT.
'/user/document.php?userid='.$object->id;
178 $head[$h][1] = $langs->trans(
"Documents");
179 if (($nbFiles + $nbLinks) > 0) {
180 $head[$h][1] .=
'<span class="badge marginleftonlyshort">'.($nbFiles + $nbLinks).
'</span>';
182 $head[$h][2] =
'document';
185 $head[$h][0] = DOL_URL_ROOT.
'/user/info.php?id='.$object->id;
186 $head[$h][1] = $langs->trans(
"Info");
187 $head[$h][2] =
'info';
204 global $langs, $conf, $user;
206 $canreadperms =
true;
207 if (!empty($conf->global->MAIN_USE_ADVANCED_PERMS)) {
208 $canreadperms = ($user->admin || $user->rights->user->group_advance->readperms);
214 $head[$h][0] = DOL_URL_ROOT.
'/user/group/card.php?id='.$object->id;
215 $head[$h][1] = $langs->trans(
"GroupCard");
216 $head[$h][2] =
'group';
219 if ((!empty($conf->ldap->enabled) && !empty($conf->global->LDAP_SYNCHRO_ACTIVE))
220 && (empty($conf->global->MAIN_DISABLE_LDAP_TAB) || !empty($user->admin))) {
221 $langs->load(
"ldap");
222 $head[$h][0] = DOL_URL_ROOT.
'/user/group/ldap.php?id='.$object->id;
223 $head[$h][1] = $langs->trans(
"LDAPCard");
224 $head[$h][2] =
'ldap';
229 $head[$h][0] = DOL_URL_ROOT.
'/user/group/perms.php?id='.$object->id;
230 $head[$h][1] = $langs->trans(
"GroupRights").
'<span class="badge marginleftonlyshort">'.($object->nb_rights).
'</span>';
231 $head[$h][2] =
'rights';
253 global $langs, $conf, $user;
255 $langs->load(
"users");
259 $head[$h][0] = DOL_URL_ROOT.
'/admin/user.php';
260 $head[$h][1] = $langs->trans(
"Parameters");
261 $head[$h][2] =
'card';
264 $head[$h][0] = DOL_URL_ROOT.
'/admin/usergroup.php';
265 $head[$h][1] = $langs->trans(
"Group");
266 $head[$h][2] =
'usergroupcard';
269 $head[$h][0] = DOL_URL_ROOT.
'/user/admin/user_extrafields.php';
270 $head[$h][1] = $langs->trans(
"ExtraFields").
" (".$langs->trans(
"Users").
")";
271 $head[$h][2] =
'attributes';
274 $head[$h][0] = DOL_URL_ROOT.
'/user/admin/group_extrafields.php';
275 $head[$h][1] = $langs->trans(
"ExtraFields").
" (".$langs->trans(
"Groups").
")";
276 $head[$h][2] =
'attributes_group';
298 function showSkins($fuser, $edit = 0, $foruserprofile =
false)
300 global $conf, $langs, $db,
$form;
302 require_once DOL_DOCUMENT_ROOT.
'/core/class/html.formother.class.php';
306 $dirthemes = array(
'/theme');
307 if (!empty($conf->modules_parts[
'theme'])) {
308 foreach ($conf->modules_parts[
'theme'] as $reldir) {
309 $dirthemes = array_merge($dirthemes, (array) ($reldir.
'theme'));
312 $dirthemes = array_unique($dirthemes);
315 $selected_theme =
'';
316 if (empty($foruserprofile)) {
317 $selected_theme = $conf->global->MAIN_THEME;
319 $selected_theme = ((is_object($fuser) && !empty($fuser->conf->MAIN_THEME)) ? $fuser->conf->MAIN_THEME :
'');
323 if (empty($foruserprofile)) {
324 $hoverdisabled = (isset($conf->global->THEME_ELDY_USE_HOVER) && $conf->global->THEME_ELDY_USE_HOVER ==
'0');
326 $hoverdisabled = (is_object($fuser) ? (empty($fuser->conf->THEME_ELDY_USE_HOVER) || $fuser->conf->THEME_ELDY_USE_HOVER ==
'0') :
'');
329 $checkeddisabled =
'';
330 if (empty($foruserprofile)) {
331 $checkeddisabled = (isset($conf->global->THEME_ELDY_USE_CHECKED) && $conf->global->THEME_ELDY_USE_CHECKED ==
'0');
333 $checkeddisabled = (is_object($fuser) ? (empty($fuser->conf->THEME_ELDY_USE_CHECKED) || $fuser->conf->THEME_ELDY_USE_CHECKED ==
'0') :
'');
337 if ($foruserprofile) {
342 print
'<div class="div-table-responsive-no-min">';
343 print
'<table class="noborder centpercent'.($edit ?
' editmodeforshowskin' :
'').
'">';
346 if ($foruserprofile) {
347 print
'<tr class="liste_titre"><th class="titlefieldmiddle">'.$langs->trans(
"Parameter").
'</th><th>'.$langs->trans(
"DefaultValue").
'</th>';
348 print
'<th colspan="2"> </th>';
352 print
'<td>'.$langs->trans(
"DefaultSkin").
'</td>';
353 print
'<td>'.$conf->global->MAIN_THEME.
'</td>';
354 print
'<td class="nowrap left"><input id="check_MAIN_THEME" name="check_MAIN_THEME"'.($edit ?
'' :
' disabled').
' type="checkbox" '.($selected_theme ?
" checked" :
"").
'> '.$langs->trans(
"UsePersonalValue").
'</td>';
355 print
'<td> </td>';
358 $dirthemestring =
'';
359 foreach ($dirthemes as $dirtheme) {
360 $dirthemestring .=
'"'.$dirtheme.
'" ';
363 print
'<tr class="liste_titre"><th class="titlefieldmiddle">';
364 print
$form->textwithpicto($langs->trans(
"DefaultSkin"), $langs->trans(
"ThemeDir").
' : '.$dirthemestring);
366 print
'<th class="right">';
367 $url =
'https://www.dolistore.com/9-skins';
368 print
'<a href="'.$url.
'" target="_blank" rel="noopener noreferrer external">';
369 print $langs->trans(
'DownloadMoreSkins');
370 print
img_picto(
'',
'globe',
'class="paddingleft"');
375 print
'<tr><td colspan="'.$colspan.
'" class="center">';
377 if (!empty($conf->global->MAIN_FORCETHEME)) {
378 $langs->load(
"errors");
379 print $langs->trans(
"WarningThemeForcedTo", $conf->global->MAIN_FORCETHEME);
382 print
'<table class="nobordernopadding" width="100%"><tr><td><div class="center">';
385 foreach ($dirthemes as $dir) {
390 if (is_dir($dirtheme)) {
391 $handle = opendir($dirtheme);
392 if (is_resource($handle)) {
393 while (($subdir = readdir($handle)) !==
false) {
394 if (is_dir($dirtheme.
"/".$subdir) && substr($subdir, 0, 1) <>
'.'
395 && substr($subdir, 0, 3) <>
'CVS' && !preg_match(
'/common|phones/i', $subdir)) {
397 if ($conf->global->MAIN_FEATURES_LEVEL < 2 && preg_match(
'/_dev$/i', $subdir)) {
400 if ($conf->global->MAIN_FEATURES_LEVEL < 1 && preg_match(
'/_exp$/i', $subdir)) {
404 print
'<div class="inline-block" style="margin-top: 10px; margin-bottom: 10px; margin-right: 20px; margin-left: 20px;">';
405 $file = $dirtheme.
"/".$subdir.
"/thumb.png";
406 $url = $urltheme.
"/".$subdir.
"/thumb.png";
407 if (!file_exists($file)) {
408 $url = DOL_URL_ROOT.
'/public/theme/common/nophoto.png';
410 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").
'">';
411 if ($subdir == $conf->global->MAIN_THEME) {
412 $title = $langs->trans(
"ThemeCurrentlyActive");
414 $title = $langs->trans(
"ShowPreview");
416 print
'<img class="img-skinthumb shadow" src="'.$url.
'" alt="'.
dol_escape_htmltag($title).
'" title="'.
dol_escape_htmltag($title).
'" style="border: none; margin-bottom: 5px;">';
418 if ($subdir == $selected_theme) {
419 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>';
421 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>';
432 print
'</div></td></tr></table>';
437 $colorbackhmenu1 =
'';
438 $colorbackvmenu1 =
'';
439 $colortexttitlenotab =
'';
440 $colortexttitlelink =
'';
441 $colorbacktitle1 =
'';
442 $colortexttitle =
'';
443 $colorbacklineimpair1 =
'';
444 $colorbacklineimpair2 =
'';
445 $colorbacklinepair1 =
'';
446 $colorbacklinepair2 =
'';
448 $colorbacklinepairhover =
'';
449 $colorbacklinepairhover =
'';
450 $colorbacklinepairchecked =
'';
454 if (file_exists(DOL_DOCUMENT_ROOT.
'/theme/'.$conf->theme.
'/theme_vars.inc.php')) {
455 include DOL_DOCUMENT_ROOT.
'/theme/'.$conf->theme.
'/theme_vars.inc.php';
459 if ($foruserprofile) {
481 $listoftopmenumodes = array(
482 '0' => $langs->transnoentitiesnoconv(
"IconAndText"),
483 '1' => $langs->transnoentitiesnoconv(
"TextOnly"),
484 '2' => $langs->transnoentitiesnoconv(
"IconOnlyAllTextsOnHover"),
485 '3' => $langs->transnoentitiesnoconv(
"IconOnlyTextOnHover"),
486 '4' => $langs->transnoentitiesnoconv(
"IconOnly"),
488 print
'<tr class="oddeven">';
489 print
'<td>'.$langs->trans(
"TopMenuDisableImages").
'</td>';
490 print
'<td colspan="'.($colspan - 1).
'">';
493 print
$form->selectarray(
'THEME_TOPMENU_DISABLE_IMAGE', $listoftopmenumodes, isset($conf->global->THEME_TOPMENU_DISABLE_IMAGE)?$conf->global->THEME_TOPMENU_DISABLE_IMAGE:0);
495 $listoftopmenumodes[$conf->global->THEME_TOPMENU_DISABLE_IMAGE];
498 print
$form->textwithpicto(
'', $langs->trans(
"NotSupportedByAllThemes"));
504 if ($foruserprofile) {
508 print
'<tr class="oddeven"><td class="titlefieldmiddle">'.$langs->trans(
"EnableShowLogo").
'</td><td>';
513 print
yn($conf->global->MAIN_SHOW_LOGO);
515 print
$form->textwithpicto(
'', $langs->trans(
"NotSupportedByAllThemes"));
524 if ($foruserprofile) {
526 print
'<tr class="oddeven">';
527 print
'<td>'.$langs->trans(
"UseBorderOnTable").
'</td>';
528 print
'<td colspan="'.($colspan - 1).
'">';
533 print
yn($conf->global->THEME_ELDY_USEBORDERONTABLE);
535 print
$form->textwithpicto(
'', $langs->trans(
"NotSupportedByAllThemes"));
541 if ($foruserprofile) {
563 print
'<tr class="oddeven">';
564 print
'<td>'.$langs->trans(
"BackgroundColor").
'</td>';
565 print
'<td colspan="'.($colspan - 1).
'">';
568 print $formother->selectColor(
colorArrayToHex(
colorStringToArray((!empty($conf->global->THEME_ELDY_BACKBODY) ? $conf->global->THEME_ELDY_BACKBODY :
''), array()),
''),
'THEME_ELDY_BACKBODY',
'', 1,
'',
'',
'colorbackbody').
' ';
572 print
'<input type="text" class="colorthumb" disabled="disabled" style="padding: 1px; margin-top: 0; margin-bottom: 0; background-color: #'.$color.
'" value="'.$color.
'">';
574 print $langs->trans(
"Default");
577 print
' <span class="nowraponall opacitymedium">'.$langs->trans(
"Default").
'</span>: <strong>ffffff</strong> ';
578 print
$form->textwithpicto(
'', $langs->trans(
"NotSupportedByAllThemes").
', '.$langs->trans(
"PressF5AfterChangingThis"));
584 if ($foruserprofile) {
608 print
'<tr class="oddeven">';
609 print
'<td>'.$langs->trans(
"TopMenuBackgroundColor").
'</td>';
610 print
'<td colspan="'.($colspan - 1).
'">';
612 print $formother->selectColor(
colorArrayToHex(
colorStringToArray((!empty($conf->global->THEME_ELDY_TOPMENU_BACK1) ? $conf->global->THEME_ELDY_TOPMENU_BACK1 :
''), array()),
''),
'THEME_ELDY_TOPMENU_BACK1',
'', 1,
'',
'',
'colorbackhmenu1').
' ';
616 print
'<input type="text" class="colorthumb" disabled="disabled" style="padding: 1px; margin-top: 0; margin-bottom: 0; background-color: #'.$color.
'" value="'.$color.
'">';
618 print $langs->trans(
"Default");
621 print
' <span class="nowraponall opacitymedium">'.$langs->trans(
"Default").
'</span>: <strong>'.$default.
'</strong> ';
622 print
$form->textwithpicto(
'', $langs->trans(
"NotSupportedByAllThemes").
', '.$langs->trans(
"PressF5AfterChangingThis"));
628 if ($foruserprofile) {
652 print
'<tr class="oddeven">';
653 print
'<td>'.$langs->trans(
"LeftMenuBackgroundColor").
'</td>';
654 print
'<td colspan="'.($colspan - 1).
'">';
656 print $formother->selectColor(
colorArrayToHex(
colorStringToArray((!empty($conf->global->THEME_ELDY_VERMENU_BACK1) ? $conf->global->THEME_ELDY_VERMENU_BACK1 :
''), array()),
''),
'THEME_ELDY_VERMENU_BACK1',
'', 1,
'',
'',
'colorbackvmenu1').
' ';
660 print
'<input type="text" class="colorthumb" disabled="disabled" style="padding: 1px; margin-top: 0; margin-bottom: 0; background-color: #'.$color.
'" value="'.$color.
'">';
662 print $langs->trans(
"Default");
665 print
' <span class="nowraponall opacitymedium">'.$langs->trans(
"Default").
'</span>: <strong>'.$default.
'</strong> ';
666 print
$form->textwithpicto(
'', $langs->trans(
"NotSupportedByAllThemes").
', '.$langs->trans(
"PressF5AfterChangingThis"));
672 if ($foruserprofile) {
676 print
'<tr class="oddeven">';
677 print
'<td>'.$langs->trans(
"TextTitleColor").
'</td>';
678 print
'<td colspan="'.($colspan - 1).
'">';
680 print $formother->selectColor(
colorArrayToHex(
colorStringToArray((!empty($conf->global->THEME_ELDY_TEXTTITLENOTAB) ? $conf->global->THEME_ELDY_TEXTTITLENOTAB :
''), array()),
''),
'THEME_ELDY_TEXTTITLENOTAB',
'', 1,
'',
'',
'colortexttitlenotab').
' ';
682 print $formother->showColor($conf->global->THEME_ELDY_TEXTTITLENOTAB, $langs->trans(
"Default"));
684 print
' <span class="nowraponall opacitymedium">'.$langs->trans(
"Default").
'</span>: <strong><span style="color: #'.$default.
'">'.$default.
'</span></strong> ';
685 print
$form->textwithpicto(
'', $langs->trans(
"NotSupportedByAllThemes").
', '.$langs->trans(
"PressF5AfterChangingThis"));
692 if ($foruserprofile) {
696 print
'<tr class="oddeven">';
697 print
'<td>'.$langs->trans(
"BackgroundTableTitleColor").
'</td>';
698 print
'<td colspan="'.($colspan - 1).
'">';
700 print $formother->selectColor(
colorArrayToHex(
colorStringToArray((!empty($conf->global->THEME_ELDY_BACKTITLE1) ? $conf->global->THEME_ELDY_BACKTITLE1 :
''), array()),
''),
'THEME_ELDY_BACKTITLE1',
'', 1,
'',
'',
'colorbacktitle1').
' ';
702 print $formother->showColor($conf->global->THEME_ELDY_BACKTITLE1, $langs->trans(
"Default"));
704 print
' <span class="nowraponall opacitymedium">'.$langs->trans(
"Default").
'</span>: <strong>'.$default.
'</strong> ';
705 print
$form->textwithpicto(
'', $langs->trans(
"NotSupportedByAllThemes").
', '.$langs->trans(
"PressF5AfterChangingThis"));
712 if ($foruserprofile) {
716 print
'<tr class="oddeven">';
717 print
'<td>'.$langs->trans(
"BackgroundTableTitleTextColor").
'</td>';
718 print
'<td colspan="'.($colspan - 1).
'">';
720 print $formother->selectColor(
colorArrayToHex(
colorStringToArray((!empty($conf->global->THEME_ELDY_TEXTTITLE) ? $conf->global->THEME_ELDY_TEXTTITLE :
''), array()),
''),
'THEME_ELDY_TEXTTITLE',
'', 1,
'',
'',
'colortexttitle').
' ';
722 print $formother->showColor($conf->global->THEME_ELDY_TEXTTITLE, $langs->trans(
"Default"));
724 print
' <span class="nowraponall opacitymedium">'.$langs->trans(
"Default").
'</span>: <strong><span style="color: #'.$default.
'">'.$default.
'</span></strong> ';
725 print
$form->textwithpicto(
'', $langs->trans(
"NotSupportedByAllThemes").
', '.$langs->trans(
"PressF5AfterChangingThis"));
732 if ($foruserprofile) {
736 print
'<tr class="oddeven">';
737 print
'<td>'.$langs->trans(
"BackgroundTableTitleTextlinkColor").
'</td>';
738 print
'<td colspan="'.($colspan - 1).
'">';
740 print $formother->selectColor(
colorArrayToHex(
colorStringToArray((!empty($conf->global->THEME_ELDY_TEXTTITLELINK) ? $conf->global->THEME_ELDY_TEXTTITLELINK :
''), array()),
''),
'THEME_ELDY_TEXTTITLELINK',
'', 1,
'',
'',
'colortexttitlelink').
' ';
742 print $formother->showColor($conf->global->THEME_ELDY_TEXTTITLELINK, $langs->trans(
"Default"));
744 print
' <span class="nowraponall opacitymedium">'.$langs->trans(
"Default").
'</span>: <strong><span style="color: #'.$default.
'">'.$default.
'</span></strong> ';
745 print
$form->textwithpicto(
'', $langs->trans(
"NotSupportedByAllThemes").
', '.$langs->trans(
"PressF5AfterChangingThis"));
753 if ($foruserprofile) {
757 print
'<tr class="oddeven">';
758 print
'<td>'.$langs->trans(
"BackgroundTableLineOddColor").
'</td>';
759 print
'<td colspan="'.($colspan - 1).
'">';
761 print $formother->selectColor(
colorArrayToHex(
colorStringToArray((!empty($conf->global->THEME_ELDY_LINEIMPAIR1) ? $conf->global->THEME_ELDY_LINEIMPAIR1 :
''), array()),
''),
'THEME_ELDY_LINEIMPAIR1',
'', 1,
'',
'',
'colorbacklineimpair2').
' ';
765 print
'<input type="text" class="colorthumb" disabled="disabled" style="padding: 1px; margin-top: 0; margin-bottom: 0; background-color: #'.$color.
'" value="'.$color.
'">';
767 print $langs->trans(
"Default");
770 print
' <span class="nowraponall opacitymedium">'.$langs->trans(
"Default").
'</span>: <strong>'.$default.
'</strong> ';
771 print
$form->textwithpicto(
'', $langs->trans(
"NotSupportedByAllThemes").
', '.$langs->trans(
"PressF5AfterChangingThis"));
777 if ($foruserprofile) {
781 print
'<tr class="oddeven">';
782 print
'<td>'.$langs->trans(
"BackgroundTableLineEvenColor").
'</td>';
783 print
'<td colspan="'.($colspan - 1).
'">';
785 print $formother->selectColor(
colorArrayToHex(
colorStringToArray((!empty($conf->global->THEME_ELDY_LINEPAIR1) ? $conf->global->THEME_ELDY_LINEPAIR1 :
''), array()),
''),
'THEME_ELDY_LINEPAIR1',
'', 1,
'',
'',
'colorbacklinepair2').
' ';
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) {
825 print
'<tr class="oddeven">';
826 print
'<td>'.$langs->trans(
"LinkColor").
'</td>';
827 print
'<td colspan="'.($colspan - 1).
'">';
829 print $formother->selectColor(
colorArrayToHex(
colorStringToArray((!empty($conf->global->THEME_ELDY_TEXTLINK) ? $conf->global->THEME_ELDY_TEXTLINK :
''), array()),
''),
'THEME_ELDY_TEXTLINK',
'', 1,
'',
'',
'colortextlink').
' ';
833 print
'<input type="text" class="colorthumb" disabled="disabled" style="padding: 1px; margin-top: 0; margin-bottom: 0; background-color: #'.$color.
'" value="'.$color.
'">';
837 print $langs->trans(
"Default");
840 print
' <span class="nowraponall opacitymedium">'.$langs->trans(
"Default").
'</span>: <strong><span style="color: #'.$default.
'">'.$default.
'</span></strong> ';
841 print
$form->textwithpicto(
'', $langs->trans(
"NotSupportedByAllThemes").
', '.$langs->trans(
"PressF5AfterChangingThis"));
847 if ($foruserprofile) {
861 print
'<tr class="oddeven">';
862 print
'<td>'.$langs->trans(
"HighlightLinesColor").
'</td>';
863 print
'<td colspan="'.($colspan - 1).
'">';
867 if (!empty($conf->global->THEME_ELDY_USE_HOVER) && $conf->global->THEME_ELDY_USE_HOVER ==
'1') {
872 print $formother->selectColor($color,
'THEME_ELDY_USE_HOVER',
'', 1,
'',
'',
'colorbacklinepairhover').
' ';
874 if ($conf->global->THEME_ELDY_USE_HOVER ==
'1') {
881 print
'<input type="text" class="colorthumb" disabled="disabled" style="padding: 1px; margin-top: 0; margin-bottom: 0; background-color: #'.$color.
'" value="'.$color.
'">';
883 print $langs->trans(
"Default");
886 print $langs->trans(
"Default");
889 print
' <span class="nowraponall opacitymedium">'.$langs->trans(
"Default").
'</span>: <strong>'.$default.
'</strong> ';
890 print
$form->textwithpicto(
'', $langs->trans(
"NotSupportedByAllThemes").
', '.$langs->trans(
"PressF5AfterChangingThis"));
895 if ($foruserprofile) {
909 print
'<tr class="oddeven">';
910 print
'<td>'.$langs->trans(
"HighlightLinesChecked").
'</td>';
911 print
'<td colspan="'.($colspan - 1).
'">';
915 if (!empty($conf->global->THEME_ELDY_USE_CHECKED) && $conf->global->THEME_ELDY_USE_CHECKED ==
'1') {
920 print $formother->selectColor($color,
'THEME_ELDY_USE_CHECKED',
'', 1,
'',
'',
'colorbacklinepairchecked').
' ';
922 if ($conf->global->THEME_ELDY_USE_CHECKED ==
'1') {
928 if ($color !=
'e6edf0') {
929 print
'<input type="text" class="colorthumb" disabled="disabled" style="padding: 1px; margin-top: 0; margin-bottom: 0; background-color: #'.$color.
'" value="'.$color.
'">';
931 print $langs->trans(
"Default");
934 print $langs->trans(
"Default");
937 print
' <span class="nowraponall opacitymedium">'.$langs->trans(
"Default").
'</span>: <strong>'.$default.
'</strong> ';
938 print
$form->textwithpicto(
'', $langs->trans(
"NotSupportedByAllThemes").
', '.$langs->trans(
"PressF5AfterChangingThis"));
944 if ($foruserprofile) {
968 print
'<tr class="oddeven">';
969 print
'<td>'.$langs->trans(
"BtnActionColor").
'</td>';
970 print
'<td colspan="'.($colspan - 1).
'">';
972 print $formother->selectColor(
colorArrayToHex(
colorStringToArray((!empty($conf->global->THEME_ELDY_BTNACTION) ? $conf->global->THEME_ELDY_BTNACTION :
''), array()),
''),
'THEME_ELDY_BTNACTION',
'', 1,
'',
'',
'butactionbg').
' ';
976 print
'<input type="text" class="colorthumb" disabled="disabled" style="padding: 1px; margin-top: 0; margin-bottom: 0; background-color: #'.$color.
'" value="'.$color.
'">';
980 print $langs->trans(
"Default");
983 print
' <span class="nowraponall opacitymedium">'.$langs->trans(
"Default").
'</span>: <strong><span style="color: #'.$default.
'">'.$default.
'</span></strong> ';
984 print
$form->textwithpicto(
'', $langs->trans(
"NotSupportedByAllThemes").
', '.$langs->trans(
"PressF5AfterChangingThis"));
990 if ($foruserprofile) {
1014 print
'<tr class="oddeven">';
1015 print
'<td>'.$langs->trans(
"TextBtnActionColor").
'</td>';
1016 print
'<td colspan="'.($colspan - 1).
'">';
1018 print $formother->selectColor(
colorArrayToHex(
colorStringToArray((!empty($conf->global->THEME_ELDY_TEXTBTNACTION) ? $conf->global->THEME_ELDY_TEXTBTNACTION :
''), array()),
''),
'THEME_ELDY_TEXTBTNACTION',
'', 1,
'',
'',
'textbutaction').
' ';
1022 print
'<input type="text" class="colorthumb" disabled="disabled" style="padding: 1px; margin-top: 0; margin-bottom: 0; background-color: #'.$color.
'" value="'.$color.
'">';
1026 print $langs->trans(
"Default");
1029 print
' <span class="nowraponall opacitymedium">'.$langs->trans(
"Default").
'</span>: <strong><span style="color: #000">'.$default.
'</span></strong> ';
1030 print
$form->textwithpicto(
'', $langs->trans(
"NotSupportedByAllThemes").
', '.$langs->trans(
"PressF5AfterChangingThis"));
1036 if ($foruserprofile) {
1038 $default = $langs->trans(
'No');
1039 print
'<tr class="oddeven">';
1040 print
'<td>'.$langs->trans(
"MAIN_OPTIMIZEFORTEXTBROWSER").
'</td>';
1041 print
'<td colspan="'.($colspan - 1).
'">';
1044 print
$form->selectyesno(
'MAIN_OPTIMIZEFORTEXTBROWSER', $fuser->conf->MAIN_OPTIMIZEFORTEXTBROWSER, 1);
1046 if (empty($conf->global->MAIN_OPTIMIZEFORTEXTBROWSER)) {
1047 print
yn($fuser->conf->MAIN_OPTIMIZEFORTEXTBROWSER);
1050 if (empty($fuser->conf->MAIN_OPTIMIZEFORTEXTBROWSER)) {
1051 print
' ('.$langs->trans(
"ForcedByGlobalSetup").
')';
1055 print
' <span class="opacitymedium">'.$langs->trans(
"Default").
'</span>: <strong>'.$default.
'</strong> ';
1056 print
$form->textwithpicto(
'', $langs->trans(
"MAIN_OPTIMIZEFORTEXTBROWSERDesc"));
1081 if ($foruserprofile && !empty($fuser->conf->MAIN_OPTIMIZEFORCOLORBLIND)) {
1083 $default = $langs->trans(
'No');
1084 print
'<tr class="oddeven">';
1085 print
'<td>'.$langs->trans(
"MAIN_OPTIMIZEFORCOLORBLIND").
'</td>';
1086 print
'<td colspan="'.($colspan - 1).
'">';
1088 $colorBlindOptions = array(
1089 0 => $langs->trans(
'No'),
1090 'flashy' => $langs->trans(
'Flashy'),
1091 'protanopia' => $langs->trans(
'Protanopia'),
1092 'deuteranopes' => $langs->trans(
'Deuteranopes'),
1093 'tritanopes' => $langs->trans(
'Tritanopes'),
1097 print
$form->selectArray(
'MAIN_OPTIMIZEFORCOLORBLIND', $colorBlindOptions, $fuser->conf->MAIN_OPTIMIZEFORCOLORBLIND, 0);
1099 if (!empty($fuser->conf->MAIN_OPTIMIZEFORCOLORBLIND) && isset($colorBlindOptions[$fuser->conf->MAIN_OPTIMIZEFORCOLORBLIND])) {
1100 print $colorBlindOptions[$fuser->conf->MAIN_OPTIMIZEFORCOLORBLIND];
1105 print
' <span class="opacitymedium">'.$langs->trans(
"Default").
'</span>: <strong>'.$default.
'</strong> ';
1106 print
$form->textwithpicto(
'', $langs->trans(
"MAIN_OPTIMIZEFORCOLORBLINDDesc"));