View file shcms/private_menu.php

File size: 2.37Kb
<?
/*
=============================================
Движок: SHCMS Engine
=============================================
Название файла: Личное меню
=============================================
Official website: http://shcms.ru
=============================================
*/
define('SHCMS', true);
include_once'../system/inc/system_core.php';
$shcmsengine['title'] = Lang::get('Личное меню %s',$login);
include_once'../template/head.php';
engine::available();
switch($act):
    default:

	   $block_while = mysql_query("SELECT * FROM `private_menu` ORDER BY  `mesto`");
		while($while_block = mysql_fetch_array($block_while)) {
			if($while_block['close'] == 1) {
				if($while_block['teams'] == 0) {
				//Вывод всех разделов с иконками
	    			if($while_block['themes'] == 'razdel') {
						echo '<div class="maintitle2 mainrazd"><img src="/template/icon/'.$while_block['icons'].'"> '.$while_block['name'].'</div>';
				//Вывод пунктов с счетчиками
					} elseif($while_block['themes'] == 'block') {
	    				echo '<div class="maintext"><a href="'.$while_block['links'].'">'.$while_block['name'].'</a>';
                    	include_once H. 'system/counts/private_menu/'.$while_block['counts'];
						echo '</div>';
					}
				//Проверка на прав к админки
				}elseif($while_block['teams'] == 6 and $users_user['team'] == 6) {
				
		    		if($while_block['themes'] == 'razdel') {
						echo '<div class="maintitle2 mainrazd"><img src="/template/icon/'.$while_block['icons'].'"> '.$while_block['name'].'</div>';
					}
	   				elseif($while_block['themes'] == 'block') {
	    				echo '<div class="posts"><a href="'.$while_block['links'].'"><strong>'.$while_block['name'].'</strong></a></div>';
					}
				}
			}
		}	
	   
	   
	break;
	
	case 'profile':
      echo '<div class="maintitle"><img src="../template/icon/menu.png"/> <b class="mainrazd">'.Lang::get('Мой профиль').'</b></div>';
	echo '<div class="maintext"><div class="posts"><a href="'.DIR_SHCMS.'change_view.php">'.Lang::get('Посмотреть профиль').'</a></div>';
      echo '<div class="posts"><a href="'.DIR_SHCMS.'change_profile.php">'.Lang::get('Изменить профиль').'</a></div></div>';
	
	break;

endswitch;	
include_once'../template/foot.php';
?>