Файл: common.php
Строк: 65
<?php
// Криме / Krime
include('settings.php');
include('/inc/general.php');
include('/inc/session.php');
require_once('/inc/mysql.php');
require_once('/inc/security.php');
require_once('/inc/auth.php');
require_once('/inc/template.php');
require_once('/inc/bbcode.php');
require_once('/inc/smiles.php');
require_once('/inc/forums.php');
require_once('/inc/threads.php');
$set=mysql_fetch_assoc(mysql_query("select * from `settings` where `id`='1'"));
$qwer=mysql_fetch_assoc(mysql_query("select * from `users` where `id`='".getid()."'"));
$jaz2=mysql_fetch_assoc(mysql_query("select * from `language` order by `id` desc limit 1"));
if(islogged()){
$jaz=mysql_fetch_assoc(mysql_query("select * from `language` where `id`='$qwer[lang]'"));
if($jaz){
include ('/lang/'.$jaz['file'].'.php');
}else{
include ('/lang/'.$jaz2['file'].'.php');
}
}else{
$setlang=mysql_fetch_assoc(mysql_query("select * from `language` where `id`='$set[lang]'"));
if($setlang){
include ('/lang/'.$setlang['file'].'.php');
}else{
include ('/lang/'.$jaz2['file'].'.php');
}
}
if(get_magic_quotes_gpc())
{
$in = array(&$_GET, &$_POST, &$_COOKIE, &$_SESSION);
while(list($k, $v) = each($in))
{
foreach($v as $key => $val)
{
if(!is_array($val))
{
$in[$k][$key] = stripslashes($val);
continue;
}
$in[] = &$in[$k][$key];
}
}
unset($in);
if(!empty($_FILES))
{
foreach($_FILES as $k => $v)
{
$_FILES[$k]['name'] = stripslashes((string)$v['name']);
}
}
}
if(checkbanned())
{
header('Location: ' . $s_bannedurl);
exit();
}
if(islogged())
{
if(checkbanned($u_username))
{
header('Location: ' . $s_bannedurl);
exit();
}
}
?>