Файл: www/chat/text_color.php
Строк: 45
<?php
include '../config.php';
if(!isset($aut)){
header('location: ../enter.php');
}else{
switch($_GET['set']){
default:
div('Цвет текста в чате');
$se=mysql_fetch_array(mysql_query("SELECT * FROM `chat_set` WHERE `id_user`='$aut[id]'"));
$color=array('По умолчанию', 'Черный', 'Белый', 'Красный', 'Оранжевый', 'Желтый', 'Синий', 'Зеленый', 'Темно-зеленый', '');
echo 'Ваш текущий цвет текста: '.$color[$se['color_us']].'<br/>';
echo 'Установите новый цвет<br/>';
echo '1. <a href="text_color.php?set=1"><font color="black">Черный</font></a><br/>';
echo '2. <a href="text_color.php?set=2"><font color="white">Белый</font></a><br/>';
echo '3. <a href="text_color.php?set=3"><font color="red">Красный</font></a><br/>';
echo '4. <a href="text_color.php?set=4"><font color="orange">Оранжевый</font></a><br/>';
echo '5. <a href="text_color.php?set=5"><font color="yellow">Желтый</font></a><br/>';
echo '6. <a href="text_color.php?set=6"><font color="blue">Синий</font></a><br/>';
echo '7. <a href="text_color.php?set=7"><font color="lime">Зеленый</font></a><br/>';
echo '8. <a href="text_color.php?set=8"><font color="green">Темно-зеленый</font></a><br/>';
echo '9. <a href="text_color.php?set=9"><font color="#FFAA00">По умолчанию</font></a><br/>';
break;
case 1:
mysql_query("UPDATE `chat_set` SET `color_text`=1 WHERE `id_user`='$aut[id]'");
header('Location: /chat/settings.php');
break;
case 2:
mysql_query("UPDATE `chat_set` SET `color_text`=2 WHERE `id_user`='$aut[id]'");
header('Location: /chat/settings.php');
break;
case 3:
mysql_query("UPDATE `chat_set` SET `color_text`=3 WHERE `id_user`='$aut[id]'");
header('Location: /chat/settings.php');
break;
case 4:
mysql_query("UPDATE `chat_set` SET `color_text`=4 WHERE `id_user`='$aut[id]'");
header('Location: /chat/settings.php');
break;
case 5:
mysql_query("UPDATE `chat_set` SET `color_text`=5 WHERE `id_user`='$aut[id]'");
header('Location: /chat/settings.php');
break;
case 6:
mysql_query("UPDATE `chat_set` SET `color_text`=6 WHERE `id_user`='$aut[id]'");
header('Location: /chat/settings.php');
break;
case 7:
mysql_query("UPDATE `chat_set` SET `color_text`=7 WHERE `id_user`='$aut[id]'");
header('Location: /chat/settings.php');
break;
case 8:
mysql_query("UPDATE `chat_set` SET `color_text`=8 WHERE `id_user`='$aut[id]'");
header('Location: /chat/settings.php');
break;
case 9:
mysql_query("UPDATE `chat_set` SET `color_text`=0 WHERE `id_user`='$aut[id]'");
header('Location: /chat/settings.php');
break;
}
echo '</div>';
echo '<div class="b"><a href="/chat/settings.php">В настройки</a></div>';}
echo '</div>';
include '../foot.php';
echo '</div>';
?>