Файл: user/panels.php
Строк: 297
<?php
/* DCMS Special
* Дата последнего редактирования 10.06.2016
* Модифицировал densnet
*/
foreach (array('start', 'compress', 'sess', 'settings', 'db_connect', 'ipua', 'fnc', 'user') as $inc) {
require_once "../sys/inc/$inc.php";
}
only_reg();
$set['title'] = lang('Настройка стилей');
include_once H . 'sys/inc/thead.php';
err();
aut();
switch ((isset($_GET['m'])) ? htmlspecialchars($_GET['m']) : null) {
default:
#Навигация
echo "<div class='list-group-item-null list-group-item-grey'><small>";
echo "<a href='/' class='hint--right' data-hint='" . lang('На главную') . "'><i class='fa fa-home fa-lg'></i></a> <i class='fa fa-angle-right fa-fw'></i> ";
echo "<a href='/?umenu'>" . lang('Кабинет') . "</a> <i class='fa fa-angle-right fa-fw'></i> ";
echo "<a href='/user/settings.php'>" . lang('Настройки') . "</a> <i class='fa fa-angle-right fa-fw'></i> ";
echo lang('Стиль панелей');
echo "</small></div><br />";
//echo "<a href='?m=settings' class='list-group-item-null'><i class='fa fa-cog fa-fw'></i> " . lang('Настройки') . "</a>";
echo "<a href='?m=style_verh' class='list-group-item-null'><font color='#$user[colorfp]'><i class='fa fa-circle fa-fw'></i></font> " . lang('Цвет вверхний градиент') . "</a>";
echo "<a href='?m=style_niz' class='list-group-item-null'><font color='#$user[colorbs]'><i class='fa fa-circle fa-fw'></i></font> " . lang('Цвет нижний градиент') . "</a>";
//echo "<a href='?m=icon_color' class='list-group-item-null'><font color='#$user[colorlp]'><i class='fa fa-circle fa-fw'></i></font> " . lang('Цвет иконок') . "</a>";
echo "<a href='?m=link_color' class='list-group-item-null'><font color='#$user[colorbp]'><i class='fa fa-circle fa-fw'></i></font> " . lang('Цвет текста заголовка') . "</a>";
break;
case 'settings':
if (isset($_POST['check'])) {
if (isset($_POST['icon_size']) && ($_POST['icon_size'] == 0 || $_POST['icon_size'] == 1 || $_POST['icon_size'] == 2)) {
mysql_query("UPDATE `user` SET `icon_size` = '" . intval($_POST['icon_size']) . "' WHERE `id` = '$user[id]' LIMIT 1");
}
$_SESSION['message'] = lang('Изменения сохранены');
header('Location: ?m=settings');
exit();
}
#Навигация
echo "<div class='list-group-item-null list-group-item-grey'><small>";
echo "<a href='/' class='hint--right' data-hint='" . lang('На главную') . "'><i class='fa fa-home fa-lg'></i></a> <i class='fa fa-angle-right fa-fw'></i> ";
echo "<a href='/?umenu'>" . lang('Кабинет') . "</a> <i class='fa fa-angle-right fa-fw'></i> ";
echo "<a href='/user/settings.php'>" . lang('Настройки') . "</a> <i class='fa fa-angle-right fa-fw'></i> ";
echo "<a href='/user/panels.php'>" . lang('Стиль панелей') . "</a> <i class='fa fa-angle-right fa-fw'></i> ";
echo lang('Настройки');
echo "</small></div><br />";
echo "<form method='post' class='list-group-item-null' action='?m=settings&$passgen'>";
echo lang('Размер иконок') . ":<br />";
echo "<select name='icon_size' class='form-control'>
<option value='0' " . ($user['icon_size'] == 0 ? " selected='selected'" : null) . ">Стандартный</option>
<option value='1' " . ($user['icon_size'] == 1 ? " selected='selected'" : null) . ">Большие</option>
<option value='2' " . ($user['icon_size'] == 2 ? " selected='selected'" : null) . ">Маленькие</option>
</select><br />";
$doc->Button('btn btn-success btn-sm', 'check', 'save', 'Сохранить');
echo "</form>";
break;
case 'style_verh':
$style = array(
'ffebee', 'ffcdd2', 'ef9a9a', 'e57373', 'ef5350', 'f44336',
'fce4ec', 'f8bbd0', 'f48fb1', 'f06292', 'ec407a', 'e91e63',
'f3e5f5', 'e1bee7', 'ce93d8', 'ba68c8', 'ab47bc', '9c27b0',
'ede7f6', 'd1c4e9', 'b39ddb', '9575cd', '7e57c2', '673ab7',
'e8eaf6', 'c5cae9', '9fa8da', '7986cb', '5c6bc0', '3f51b5',
'e3f2fd', 'bbdefb', '90caf9', '64b5f6', '42a5f5', '2196f3',
'e1f5fe', 'b3e5fc', '81d4fa', '4fc3f7', '29b6f6', '03a9f4',
'e0f7fa', 'b2ebf2', '80deea', '4dd0e1', '26c6da', '00bcd4',
'e0f2f1', 'b2dfdb', '80cbc4', '4db6ac', '26a69a', '009688',
'e8f5e9', 'c8e6c9', 'a5d6a7', '81c784', '66bb6a', '4caf50',
'f1f8e9', 'dcedc8', 'c5e1a5', 'aed581', '9ccc65', '8bc34a',
'f9fbe7', 'f0f4c3', 'e6ee9c', 'dce775', 'd4e157', 'cddc39',
'fffde7', 'fff9c4', 'fff59d', 'fff176', 'ffee58', 'ffeb3b',
'fff8e1', 'ffecb3', 'ffe082', 'ffd54f', 'ffca28', 'ffc107',
'fff3e0', 'ffe0b2', 'ffcc80', 'ffb74d', 'ffa726', 'ff9800',
'fbe9e7', 'ffccbc', 'ffab91', 'ff8a65', 'ff7043', 'ff5722',
'efebe9', 'd7ccc8', 'bcaaa4', 'a1887f', '8d6e63', '795548',
'fafafa', 'f5f5f5', 'eeeeee', 'e0e0e0', 'bdbdbd', '9e9e9e'
);
if (isset($_GET['ok']) && isset($_GET['color']) && $_GET['color'] < 108) {
$st = intval($_GET['color']);
$user['colorfp'] = $style[$st];
mysql_query("UPDATE `user` SET `colorfp` = '" . $user['colorfp'] . "', `panel` = '" . $st . "' WHERE `id` = '$user[id]' LIMIT 1");
header('Location: ?m=style_verh');
$_SESSION['message'] = lang('Изменения сохранены');
exit();
}
#Навигация
echo "<div class='list-group-item-null list-group-item-grey'><small>";
echo "<a href='/' class='hint--right' data-hint='" . lang('На главную') . "'><i class='fa fa-home fa-lg'></i></a> <i class='fa fa-angle-right fa-fw'></i> ";
echo "<a href='/?umenu'>" . lang('Кабинет') . "</a> <i class='fa fa-angle-right fa-fw'></i> ";
echo "<a href='/user/settings.php'>" . lang('Настройки') . "</a> <i class='fa fa-angle-right fa-fw'></i> ";
echo "<a href='/user/panels.php'>" . lang('Стиль панелей') . "</a> <i class='fa fa-angle-right fa-fw'></i> ";
echo lang('Выберите цвет');
echo "</small></div><br />";
?>
<style>
.ovs{overflow: hidden;}
.panels {padding: 11px 10px;}
.panel_u{float:left}
</style>
<div class="list-group-item-null" style="padding-bottom:0;">Выберите цвет панели:</div>
<div class="ovs list-group-item-null">
<div class="panel_u" style="width:50%;"><div style="padding-right:5px;">
<?php
for ($i = 0; $i <= 107; $i++)
echo '<div style="-webkit-border-radius: 4px; border-radius: 4px; background-color:#' . $style[$i] . '; margin-bottom: 10px; " class="ovs"><a href="/user/panels.php?m=style_verh&color=' . $i . '&ok" class="arrow_link" style="display:block; text-decoration:none; padding:5px;"><div class="ovs" style="height:19px; ' . ($user['colorfp'] == $style[$i] ? 'background: url(/style/icons/img_p.png) center no-repeat;' : null) . ' "></div></a></div>' . ($i == 53 ? '</div></div><div class="panel_u" style="width:50%;"><div style="padding-right:5px;">' : null) . '' . ($i == 107 ? '</div></div>' : null);
?>
</div>
<?php
break;
case 'style_niz':
$style = array(
'ffebee', 'ffcdd2', 'ef9a9a', 'e57373', 'ef5350', 'f44336',
'fce4ec', 'f8bbd0', 'f48fb1', 'f06292', 'ec407a', 'e91e63',
'f3e5f5', 'e1bee7', 'ce93d8', 'ba68c8', 'ab47bc', '9c27b0',
'ede7f6', 'd1c4e9', 'b39ddb', '9575cd', '7e57c2', '673ab7',
'e8eaf6', 'c5cae9', '9fa8da', '7986cb', '5c6bc0', '3f51b5',
'e3f2fd', 'bbdefb', '90caf9', '64b5f6', '42a5f5', '2196f3',
'e1f5fe', 'b3e5fc', '81d4fa', '4fc3f7', '29b6f6', '03a9f4',
'e0f7fa', 'b2ebf2', '80deea', '4dd0e1', '26c6da', '00bcd4',
'e0f2f1', 'b2dfdb', '80cbc4', '4db6ac', '26a69a', '009688',
'e8f5e9', 'c8e6c9', 'a5d6a7', '81c784', '66bb6a', '4caf50',
'f1f8e9', 'dcedc8', 'c5e1a5', 'aed581', '9ccc65', '8bc34a',
'f9fbe7', 'f0f4c3', 'e6ee9c', 'dce775', 'd4e157', 'cddc39',
'fffde7', 'fff9c4', 'fff59d', 'fff176', 'ffee58', 'ffeb3b',
'fff8e1', 'ffecb3', 'ffe082', 'ffd54f', 'ffca28', 'ffc107',
'fff3e0', 'ffe0b2', 'ffcc80', 'ffb74d', 'ffa726', 'ff9800',
'fbe9e7', 'ffccbc', 'ffab91', 'ff8a65', 'ff7043', 'ff5722',
'efebe9', 'd7ccc8', 'bcaaa4', 'a1887f', '8d6e63', '795548',
'fafafa', 'f5f5f5', 'eeeeee', 'e0e0e0', 'bdbdbd', '9e9e9e'
);
if (isset($_GET['ok']) && isset($_GET['color']) && $_GET['color'] < 108) {
$st = intval($_GET['color']);
$user['colorbs'] = $style[$st];
mysql_query("UPDATE `user` SET `colorbs` = '" . $user['colorbs'] . "', `panel` = '" . $st . "' WHERE `id` = '$user[id]' LIMIT 1");
header('Location: ?m=style_niz');
$_SESSION['message'] = lang('Изменения сохранены');
exit();
}
#Навигация
echo "<div class='list-group-item-null list-group-item-grey'><small>";
echo "<a href='/' class='hint--right' data-hint='" . lang('На главную') . "'><i class='fa fa-home fa-lg'></i></a> <i class='fa fa-angle-right fa-fw'></i> ";
echo "<a href='/?umenu'>" . lang('Кабинет') . "</a> <i class='fa fa-angle-right fa-fw'></i> ";
echo "<a href='/user/settings.php'>" . lang('Настройки') . "</a> <i class='fa fa-angle-right fa-fw'></i> ";
echo "<a href='/user/panels.php'>" . lang('Стиль панелей') . "</a> <i class='fa fa-angle-right fa-fw'></i> ";
echo lang('Выберите цвет');
echo "</small></div><br />";
?>
<style>
.ovs{overflow: hidden;}
.panels {padding: 11px 10px;}
.panel_u{float:left}
</style>
<div class="list-group-item-null" style="padding-bottom:0;">Выберите цвет панели:</div>
<div class="ovs list-group-item-null">
<div class="panel_u" style="width:50%;"><div style="padding-right:5px;">
<?php
for ($i = 0; $i <= 107; $i++)
echo '<div style="-webkit-border-radius: 4px; border-radius: 4px; background-color:#' . $style[$i] . '; margin-bottom: 10px; " class="ovs"><a href="/user/panels.php?m=style_niz&color=' . $i . '&ok" class="arrow_link" style="display:block; text-decoration:none; padding:5px;"><div class="ovs" style="height:19px; ' . ($user['colorbs'] == $style[$i] ? 'background: url(/style/icons/img_p.png) center no-repeat;' : null) . ' "></div></a></div>' . ($i == 53 ? '</div></div><div class="panel_u" style="width:50%;"><div style="padding-right:5px;">' : null) . '' . ($i == 107 ? '</div></div>' : null);
?>
</div>
<?php
break;
case 'icon_color':
$style = array(
'ffebee', 'ffcdd2', 'ef9a9a', 'e57373', 'ef5350', 'f44336',
'fce4ec', 'f8bbd0', 'f48fb1', 'f06292', 'ec407a', 'e91e63',
'f3e5f5', 'e1bee7', 'ce93d8', 'ba68c8', 'ab47bc', '9c27b0',
'ede7f6', 'd1c4e9', 'b39ddb', '9575cd', '7e57c2', '673ab7',
'e8eaf6', 'c5cae9', '9fa8da', '7986cb', '5c6bc0', '3f51b5',
'e3f2fd', 'bbdefb', '90caf9', '64b5f6', '42a5f5', '2196f3',
'e1f5fe', 'b3e5fc', '81d4fa', '4fc3f7', '29b6f6', '03a9f4',
'e0f7fa', 'b2ebf2', '80deea', '4dd0e1', '26c6da', '00bcd4',
'e0f2f1', 'b2dfdb', '80cbc4', '4db6ac', '26a69a', '009688',
'e8f5e9', 'c8e6c9', 'a5d6a7', '81c784', '66bb6a', '4caf50',
'f1f8e9', 'dcedc8', 'c5e1a5', 'aed581', '9ccc65', '8bc34a',
'f9fbe7', 'f0f4c3', 'e6ee9c', 'dce775', 'd4e157', 'cddc39',
'fffde7', 'fff9c4', 'fff59d', 'fff176', 'ffee58', 'ffeb3b',
'fff8e1', 'ffecb3', 'ffe082', 'ffd54f', 'ffca28', 'ffc107',
'fff3e0', 'ffe0b2', 'ffcc80', 'ffb74d', 'ffa726', 'ff9800',
'fbe9e7', 'ffccbc', 'ffab91', 'ff8a65', 'ff7043', 'ff5722',
'efebe9', 'd7ccc8', 'bcaaa4', 'a1887f', '8d6e63', '795548',
'fafafa', 'f5f5f5', 'eeeeee', 'e0e0e0', 'bdbdbd', '9e9e9e'
);
if (isset($_GET['ok']) && isset($_GET['color']) && $_GET['color'] < 108) {
$st = intval($_GET['color']);
$user['colorlp'] = $style[$st];
mysql_query("UPDATE `user` SET `colorlp` = '" . $user['colorlp'] . "', `panel` = '" . $st . "' WHERE `id` = '$user[id]' LIMIT 1");
header('Location: ?m=icon_color');
$_SESSION['message'] = lang('Изменения сохранены');
exit();
}
#Навигация
echo "<div class='list-group-item-null list-group-item-grey'><small>";
echo "<a href='/' class='hint--right' data-hint='" . lang('На главную') . "'><i class='fa fa-home fa-lg'></i></a> <i class='fa fa-angle-right fa-fw'></i> ";
echo "<a href='/?umenu'>" . lang('Кабинет') . "</a> <i class='fa fa-angle-right fa-fw'></i> ";
echo "<a href='/user/settings.php'>" . lang('Настройки') . "</a> <i class='fa fa-angle-right fa-fw'></i> ";
echo "<a href='/user/panels.php'>" . lang('Стиль панелей') . "</a> <i class='fa fa-angle-right fa-fw'></i> ";
echo lang('Выберите цвет');
echo "</small></div><br />";
?>
<style>
.ovs{overflow: hidden;}
.panels {padding: 11px 10px;}
.panel_u{float:left}
</style>
<div class="list-group-item-null" style="padding-bottom:0;">Выберите цвет панели:</div>
<div class="ovs list-group-item-null">
<div class="panel_u" style="width:50%;"><div style="padding-right:5px;">
<?php
for ($i = 0; $i <= 107; $i++)
echo '<div style="-webkit-border-radius: 4px; border-radius: 4px; background-color:#' . $style[$i] . '; margin-bottom: 10px; " class="ovs"><a href="/user/panels.php?m=icon_color&color=' . $i . '&ok" class="arrow_link" style="display:block; text-decoration:none; padding:5px;"><div class="ovs" style="height:19px; ' . ($user['colorlp'] == $style[$i] ? 'background: url(/style/icons/img_p.png) center no-repeat;' : null) . ' "></div></a></div>' . ($i == 53 ? '</div></div><div class="panel_u" style="width:50%;"><div style="padding-right:5px;">' : null) . '' . ($i == 107 ? '</div></div>' : null);
?>
</div>
<?php
break;
case 'link_color':
$style = array(
'ffebee', 'ffcdd2', 'ef9a9a', 'e57373', 'ef5350', 'f44336',
'fce4ec', 'f8bbd0', 'f48fb1', 'f06292', 'ec407a', 'e91e63',
'f3e5f5', 'e1bee7', 'ce93d8', 'ba68c8', 'ab47bc', '9c27b0',
'ede7f6', 'd1c4e9', 'b39ddb', '9575cd', '7e57c2', '673ab7',
'e8eaf6', 'c5cae9', '9fa8da', '7986cb', '5c6bc0', '3f51b5',
'e3f2fd', 'bbdefb', '90caf9', '64b5f6', '42a5f5', '2196f3',
'e1f5fe', 'b3e5fc', '81d4fa', '4fc3f7', '29b6f6', '03a9f4',
'e0f7fa', 'b2ebf2', '80deea', '4dd0e1', '26c6da', '00bcd4',
'e0f2f1', 'b2dfdb', '80cbc4', '4db6ac', '26a69a', '009688',
'e8f5e9', 'c8e6c9', 'a5d6a7', '81c784', '66bb6a', '4caf50',
'f1f8e9', 'dcedc8', 'c5e1a5', 'aed581', '9ccc65', '8bc34a',
'f9fbe7', 'f0f4c3', 'e6ee9c', 'dce775', 'd4e157', 'cddc39',
'fffde7', 'fff9c4', 'fff59d', 'fff176', 'ffee58', 'ffeb3b',
'fff8e1', 'ffecb3', 'ffe082', 'ffd54f', 'ffca28', 'ffc107',
'fff3e0', 'ffe0b2', 'ffcc80', 'ffb74d', 'ffa726', 'ff9800',
'fbe9e7', 'ffccbc', 'ffab91', 'ff8a65', 'ff7043', 'ff5722',
'efebe9', 'd7ccc8', 'bcaaa4', 'a1887f', '8d6e63', '795548',
'fafafa', 'f5f5f5', 'eeeeee', 'e0e0e0', 'bdbdbd', '9e9e9e'
);
if (isset($_GET['ok']) && isset($_GET['color']) && $_GET['color'] < 108) {
$st = intval($_GET['color']);
$user['colorbp'] = $style[$st];
mysql_query("UPDATE `user` SET `colorbp` = '" . $user['colorbp'] . "', `panel` = '" . $st . "' WHERE `id` = '$user[id]' LIMIT 1");
header('Location: ?m=link_color');
$_SESSION['message'] = lang('Изменения сохранены');
exit();
}
#Навигация
echo "<div class='list-group-item-null list-group-item-grey'><small>";
echo "<a href='/' class='hint--right' data-hint='" . lang('На главную') . "'><i class='fa fa-home fa-lg'></i></a> <i class='fa fa-angle-right fa-fw'></i> ";
echo "<a href='/?umenu'>" . lang('Кабинет') . "</a> <i class='fa fa-angle-right fa-fw'></i> ";
echo "<a href='/user/settings.php'>" . lang('Настройки') . "</a> <i class='fa fa-angle-right fa-fw'></i> ";
echo "<a href='/user/panels.php'>" . lang('Стиль панелей') . "</a> <i class='fa fa-angle-right fa-fw'></i> ";
echo lang('Выберите цвет');
echo "</small></div><br />";
?>
<style>
.ovs{overflow: hidden;}
.panels {padding: 11px 10px;}
.panel_u{float:left}
</style>
<div class="list-group-item-null" style="padding-bottom:0;">Выберите цвет панели:</div>
<div class="ovs list-group-item-null">
<div class="panel_u" style="width:50%;"><div style="padding-right:5px;">
<?php
for ($i = 0; $i <= 107; $i++)
echo '<div style="-webkit-border-radius: 4px; border-radius: 4px; background-color:#' . $style[$i] . '; margin-bottom: 10px; " class="ovs"><a href="/user/panels.php?m=link_color&color=' . $i . '&ok" class="arrow_link" style="display:block; text-decoration:none; padding:5px;"><div class="ovs" style="height:19px; ' . ($user['colorbp'] == $style[$i] ? 'background: url(/style/icons/img_p.png) center no-repeat;' : null) . ' "></div></a></div>' . ($i == 53 ? '</div></div><div class="panel_u" style="width:50%;"><div style="padding-right:5px;">' : null) . '' . ($i == 107 ? '</div></div>' : null);
?>
</div>
<?php
break;
}
include_once H . 'sys/inc/tfoot.php';