Просмотр файла incfiles/index_menu.php

Размер файла: 4.27Kb
<?
echo '<div class="razd">Общение</div>

<a class="link" href="/mini_chat/">'. (isset($user) && $settings['img_site'] == 2?NULL:'<img src="/design/icons/mini.png" alt="" /> ') .' Мини-чат ('. mysql_result(mysql_query("SELECT COUNT(*) FROM `mini_chat`"), 0) .')</a>';
# Проверяем, закрыт ли модуль Форум
if ($system['forum_module'] == '2')$close_forum="Закрыт";
else $close_forum="";
# Проверяем, закрыт ли модуль Форум
if ($system['forum_module'] == '2')$close_forum='<div class="err">Форум закрыт</div>';
else $close_forum="";
echo'<a class="link" href="/forum/">'. (isset($user) && $settings['img_site'] == 2?NULL:'<img src="/design/icons/forum/index.png" alt="" /> ') .' Форум ('. $forum_count .')</a> '. $close_forum .'';

if ($system['diray_module'] == '2')$close_diray='<div class="err">Дневники закрыты</div>';
else $close_diray="";
echo'<a class="link" href="/diray/">'. (isset($user) && $settings['img_site'] == 2?NULL:'<img src="/design/icons/diray/index.png" alt="" /> ') .' Дневники ('. $diray_count .')</a> '. $close_diray .'';



//if ($loads_count == 0){
echo '<div class="razd">Загруз-центр</div>';
echo '<a class="link" href="/downloads/"><img src="/design/icons/loads.png" alt="" /> Загруз-центр</a>';
/*}else{
echo '<div class="razd"><a href="/downloads/">Загруз-центр</a></div>';
# Запрос для вывода папок
$sql_downloads = mysql_query("SELECT * FROM `downloads` WHERE `dir_id` = '0' ORDER BY type ASC, name ASC");
# Цикл извлечения данных
while ($download = mysql_fetch_assoc($sql_downloads)) {
if ($download['type'] == 1) {
if (mysql_result(mysql_query("SELECT COUNT(*) FROM `downloads` WHERE `path` LIKE '%$download[path]%' AND `id` != '$download[id]' AND `type` = '2' AND `time` > '". (time()-3600*24*3) ."'"), 0) != 0) $new1 = '<span class="green">+'. mysql_result(mysql_query("SELECT COUNT(*) FROM `downloads` WHERE `path` LIKE '%$download[path]%' AND `id` != '$download[id]' AND `type` = '2' AND `time` > '". (time()-3600*24*3) ."'"), 0) .'</span>';
else $new1 = '';

if (mysql_result(mysql_query("SELECT COUNT(*) FROM `downloads` WHERE `path` LIKE '%$download[path]%' AND `id` != '$download[id]' AND `type` = '2' AND `time` > '". (time()-3600*24*7) ."'"), 0) != 0) $new2 = '<span class="red">+'. mysql_result(mysql_query("SELECT COUNT(*) FROM `downloads` WHERE `path` LIKE '%$download[path]%' AND `id` != '$download[id]' AND `type` = '2' AND `time` > '". (time()-3600*24*7) ."'"), 0) .'</span>';
else $new2 = '';

if ($new1 != NULL || $new2 != NULL) $new3 = $new1 . $new2;
else $new3 = '';
}
echo '<div class="link"><img src="/design/icons/downloads/'. ($download['file_ext'] != NULL?$download['file_ext']:'file') .'.png" alt="'. ($download['type'] == 1?'Папка':'Файл') .'"> <a href="/downloads/'. ($download['type'] == 1?'index.php?dir_id='. $download['id']:'file.php?file_id='. $download['id']) .'">'. $download['name'] .'</a>'. ($download['type'] == 2?' ('. vtime($download['time']) .')':' ('. mysql_result(mysql_query("SELECT COUNT(*) FROM `downloads` WHERE `path` LIKE '%$download[path]%' AND `id` != '$download[id]' AND `type` = '2'"), 0) .')'. ($new3 != NULL?' '. $new3:NULL)) . ($download['type'] == 1 && user_access('add_dir_downloads')?' [<a href="/downloads/index.php?dir_id='. $dir_id .'&edit_id='. $download['id'] .'">изм</a>] [<a href="/downloads/index.php?dir_id='. $dir_id .'&delete_id='. $download['id'] .'">уд</a>]':NULL) .'</div>';
}
}*/


// Блок статистики
echo '<div class="razd">Статистика</div>
<a class="link" href="/user/users_online.php">'. (isset($user) && $settings['img_site'] == 2?NULL:'<img src="/design/icons/user/online.png" alt="" /> ') .' Пользователи онлайн ('. $users_online .')</a>
<a class="link" href="/user/guests_online.php">'. (isset($user) && $settings['img_site'] == 2?NULL:'<img src="/design/icons/user/online.png" alt="" /> ') .' Гости онлайн ('. $guest_online .')</a>
<a class="link" href="/user/list_users.php">'. (isset($user) && $settings['img_site'] == 2?NULL:'<img src="/design/icons/user/list_users.png" alt="" /> ') .' Список пользователей ('. $users .')</a>';

?>