Файл: vsime.com/system/functions/dir_files_info.php
Строк: 17
<?
function dir_files_info ($dir_id)
{
global $dbi, $user, $no_hack, $title, $config;
if (mysqli_result("SELECT COUNT(*) FROM `files` WHERE `id` = '$dir_id' AND `type` = 'dir'"))
{
$dir = mysqli_fetch_array(mysqli_query($dbi, "SELECT * FROM `files` WHERE `id` = '$dir_id' AND `type` = 'dir'"));
$dir['dir_img'] = dir_img($dir['access']);
$dir['counter'] .= $dir['id']."/";
}
else
{
$ank = profile($user['id']);
if (isset($no_hack))
{
if (isset($_GET['id']))
{
$ank = profile(intval(@$_GET['id']));
if ($ank['id'] == 0)
{
$title .= ' - Ошибка!';
ex_head();
show_errors('Пользователь не найден');
ex_foot();
}
} else {
if_user('is_reg');
$ank = $user;
}
}
$dir = array();
$dir['id'] = 0;
$dir['id_user'] = $ank['id'];
$dir['name'] = "Файлы";
$dir['counter'] = '/0/';
$dir['access'] = 'all';
$dir['dir_img'] = dir_img($dir['access']);
}
return $dir;
}
?>