<?php
require( "../inc/conf.inc.php" );
require( "../inc/check.php" );
if ( empty( $avator ) )
{
echo "<title>Аватор</title>";
echo "<style type=\"text/css\">";
echo "body { font-size: {$fs}; color: {$tcol}; background-color: {$bcol} }";
echo "a:link,a:visited { text-decoration: underline; color: {$lcol} }";
echo "div { border-style:solid; border-width: 1px; background-color: {$rcol} }";
echo "</style>";
echo "</head>";
echo "<body>";
echo "<div align=\"center\"><b>".$row['login']."</b>! Здесь ты можеш выбрать сибе аватор</div><br/>";
echo "<div>";
echo "<a href=\"avator.php?ci={$ci}&amp;id={$id}&amp;pass={$pass}&amp;avator=100\"><b>Отключить аватор</b></a><br>****<br/>";
echo "<a href=\"avator.php?ci={$ci}&amp;id={$id}&amp;pass={$pass}&amp;avator=99\"><b>Закрепить загруженный</b></a><br>****<br/>";
echo "<a href=\"avator.php?ci={$ci}&amp;id={$id}&amp;pass={$pass}&amp;avator=1\"><img src=\"../avator/1.gif\" alt=\"1\"/></a><br>****<br/>";
echo "<a href=\"avator.php?ci={$ci}&amp;id={$id}&amp;pass={$pass}&amp;avator=2\"><img src=\"../avator/2.gif\" alt=\"2\"/></a><br>****<br/>";
echo "<a href=\"avator.php?ci={$ci}&amp;id={$id}&amp;pass={$pass}&amp;avator=3\"><img src=\"../avator/3.gif\" alt=\"3\"/></a><br>****<br/>";
echo "<a href=\"avator.php?ci={$ci}&amp;id={$id}&amp;pass={$pass}&amp;avator=4\"><img src=\"../avator/4.gif\" alt=\"4\"/></a><br>****<br/>";
echo "<a href=\"avator.php?ci={$ci}&amp;id={$id}&amp;pass={$pass}&amp;avator=5\"><img src=\"../avator/5.gif\" alt=\"5\"/></a><br>****<br/>";
echo "<a href=\"avator.php?ci={$ci}&amp;id={$id}&amp;pass={$pass}&amp;avator=6\"><img src=\"../avator/6.gif\" alt=\"6\"/></a><br>****<br/>";
echo "<a href=\"avator.php?ci={$ci}&amp;id={$id}&amp;pass={$pass}&amp;avator=7\"><img src=\"../avator/7.gif\" alt=\"7\"/></a><br>****<br/>";
echo "<a href=\"avator.php?ci={$ci}&amp;id={$id}&amp;pass={$pass}&amp;avator=8\"><img src=\"../avator/8.gif\" alt=\"8\"/></a><br>****<br/>";
echo "<a href=\"avator.php?ci={$ci}&amp;id={$id}&amp;pass={$pass}&amp;avator=9\"><img src=\"../avator/9.gif\" alt=\"9\"/></a><br>****<br/>";
echo "<a href=\"avator.php?ci={$ci}&amp;id={$id}&amp;pass={$pass}&amp;avator=10\"><img src=\"../avator/10.gif\" alt=\"10\"/></a><br>****<br/>";
}
else
{
echo "<meta http-equiv=\"refresh\" content=\"1;URL=gipermarket.php?ci={$ci}&amp;id={$id}&amp;pass={$pass}\"/>";
echo "<title>avator</title>";
echo "<style type=\"text/css\">";
echo "body { font-size: {$fs}; color: {$tcol}; background-color: {$bcol} }";
echo "a:link,a:visited { text-decoration: underline; color: {$lcol} }";
echo "div { border-style:solid; border-width: 1px; background-color: {$rcol} }";
echo "</style>";
echo "</head>";
echo "<body>";
echo "<div align=\"center\">";
$avator = intval( $avator );
$query = mysql_query( "update users set avator='".$avator."'  where id='".$id."';" );
if ( $query )
{
print "Настройки для вашего профиля изменены!<br/>";
}
else
{
print "Произошла непредвиденная ошибка, пожалуйсто обратитесь к администрации.<br/>";
}
}
echo "</div><br/>";
echo "|_|<a href=\"avator1.php?ci={$ci}&amp;id={$id}&amp;pass={$pass}\">2</a>|<a href=\"avator2.php?ci={$ci}&amp;id={$id}&amp;pass={$pass}\">3</a>|<a href=\"avator3.php?ci={$ci}&amp;id={$id}&amp;pass={$pass}\">4</a>|<a href=\"avator4.php?ci={$ci}&amp;id={$id}&amp;pass={$pass}\">5</a>|<br/>";
echo "<a href=\"../enter.php?ci={$ci}&amp;id={$id}&amp;pass={$pass}\">Прихожая</a><br/>";
$end = gettime( );echo "<div><b>&copy; KOT </b></div>";
echo "<p align=\"center\">";
echo "[".round( $end - $mystart, 5 )."]";
echo "</p></body></html>";
mysql_close( $link );
?>