File size: 2.19Kb
<?php
// Чат GBodr
// Версия: 1.0
// Автор: Gemorroj
require 'connect.php';
require 'header.php';
require 'result.php';
$us = $row['user'];
if($_GET['go'] != 1)
{
$bind1 = $row['bind1'];
$bind2 = $row['bind2'];
$bind3 = $row['bind3'];
$bind4 = $row['bind4'];
print $top.'
<head><meta http-equiv="Cache-Control" content="no-cache" forua="true"/></head>
<card id="bind" title="Клавиши">
<p>
<small>
<strong>Сказать:</strong><br/>
</small>
<input name="bind1" format="1N" size="1" value="'.$bind1.'"/><br/>
<small>
<strong>Обновить:</strong><br/>
</small>
<input name="bind2" format="1N" size="1" value="'.$bind2.'"/><br/>
<small>
<strong>История:</strong><br/>
</small>
<input name="bind3" format="1N" size="1" value="'.$bind3.'"/><br/>
<small>
<strong>Прихожая:</strong><br/>
</small>
<input name="bind4" format="1N" size="1" value="'.$bind4.'"/><br/>
<small>
---<br/>
<anchor>Сохранить
<go href="bind.php?go=1&id='.$id.'&ps='.$ps.'&ref='.$ref.'" method="post">
<postfield name="bind1" value="$(bind1)"/>
<postfield name="bind2" value="$(bind2)"/>
<postfield name="bind3" value="$(bind3)"/>
<postfield name="bind4" value="$(bind4)"/>
</go></anchor><br/>
---<br/>
<a href="cabinet.php?id='.$id.'&ps='.$ps.'&ref='.$ref.'">Личный кабинет</a><br/>
<a href="enter.php?id='.$id.'&ps='.$ps.'&ref='.$ref.'">Прихожая</a>
</small>
</p>
</card>
</wml>';
mysql_close();
exit;
}
else
{
$bind1 = intval($_POST['bind1']);
$bind2 = intval($_POST['bind2']);
$bind3 = intval($_POST['bind3']);
$bind4 = intval($_POST['bind4']);
if(mysql_query("Update `antihack_users` set bind1=".$bind1.",bind2=".$bind2.",bind3=".$bind3.",bind4=".$bind4." where id=".$id))
{
$msg = 'Ваши настройки изменены';
}
else
{
$error = mysql_error();
}
mysql_close();
if(isset($error))
{
print $top.'
<card id="error" title="Error" ontimer="bind.php?id='.$id.'&ps='.$ps.'">
<timer value="5"/>
<do type="prev" label="Back"><prev/></do>
<p>
'.$error.'
</p>
</card>
</wml>';
exit;
}
else
{
print $top.'
<card id="ok" title="Ok" ontimer="cabinet.php?id='.$id.'&ps='.$ps.'&ref='.$ref.'">
<timer value="5"/>
<p>
'.$msg.'
</p>
</card>
</wml>';
}
}
?>