Файл: modules/padmin/balans.php
Строк: 78
<?php
/**********************************
* @package: PerfCMS *
* @year: 2012 *
* @author: Artas *
* @link: http://perfcms.pp.ua *
**********************************/
$locate = 'in_padmin';
if(isset($user) && $user['level'] >= 6) {
$title = $lang->word('balans_set');
require_once(SYS.'/view/header.php');
$tpl->div('title', $lang->word('balans_set'));
if(isset($_POST['save']) && $_GET['act']== 'save') {
$balans_chat = input($_POST['balans_chat']);
$balans_forum = input($_POST['balans_forum']);
$balans_obmen = input($_POST['balans_obmen']);
$db->query("UPDATE `system` SET `balans_chat` = '". $balans_chat."', `balans_forum` = '". $balans_forum."', `balans_obmen` = '". $balans_obmen."'");
$tpl->div('menu', $lang->word('succ_save'));
$tpl->div('block', img('balans.png') . '<a href="/padmin/balans/">'.$lang->word('balans_mod').'</a><br/>'. img('admin.png') .'<a href="/padmin/">'. $lang->word('padmin') .'</a><br/>'. HICO .'<a href="/">'. $lang->word('home') .'</a>');
require_once(SYS.'/view/footer.php');
exit;
}
echo '<div class="post">
<form action="/padmin/balans/?act=save" method="post">
<b>'. $lang->word('balans_chat') .'</b>:<br />
<input type="text" size="2" name="balans_chat" value="'. $system['balans_chat'] .'" /><br/>
<b>'. $lang->word('balans_forum') .'</b>:<br />
<input type="text" size="2" name="balans_forum" value="'. $system['balans_forum'] .'" /><br/>
<b>'. $lang->word('balans_obmen') .'</b>:<br />
<input type="text" size="2" name="balans_obmen" value="'. $system['balans_obmen'] .'" /><br/>
<input type="submit" name="save" value="'. $lang->word('save') .'" />
</form>
</div>';
$tpl->div('block', img('admin.png') .'<a href="/padmin/">'. $lang->word('padmin') .'</a><br/>'. HICO .'<a href="/">'. $lang->word('home') .'</a>');
require_once(SYS.'/view/footer.php');
} else { header('Location: /'); }
?>