Данный мод взят с другого сайта
В базу данных
Code:
ALTER TABLE `se_users`
ADD `friends` int(1) NOT NULL DEFAULT '1',
ADD `photos` int(1) NOT NULL DEFAULT '1',
ADD `video` int(1) NOT NULL DEFAULT '1',
ADD `audio` int(1) NOT NULL DEFAULT '1',
ADD `mail` int(1) NOT NULL DEFAULT '1',
ADD `blog` int(1) NOT NULL DEFAULT '1',
ADD `groups` int(1) NOT NULL DEFAULT '1',
ADD `news` int(1) NOT NULL DEFAULT '1',
ADD `opin` int(1) NOT NULL DEFAULT '1'
В php перед // GET PROFILE CATEGORIES
PHP:
// SAVE ACCOUNT SETTINGS
if($task == "dosave1")
{
$user->user_info['friends'] = $_POST['friends'];
$user->user_info['photos'] = $_POST['photos'];
$user->user_info['video'] = $_POST['video'];
$user->user_info['audio'] = $_POST['audio'];
$user->user_info['mail'] = $_POST['mail'];
$user->user_info['blog'] = $_POST['blog'];
$user->user_info['groups'] = $_POST['groups'];
$user->user_info['news'] = $_POST['news'];
$user->user_info['opin'] = $_POST['opin'];
$database->database_query("UPDATE se_users SET friends='{$user->user_info['friends']}',
photos='{$user->user_info['photos']}',
audio='{$user->user_info['audio']}',
mail='{$user->user_info['mail']}',
blog='{$user->user_info['blog']}',
groups='{$user->user_info['groups']}',
opin='{$user->user_info['opin']}',
news='{$user->user_info['news']}',
video='{$user->user_info['video']}' WHERE user_id='{$user->user_info['user_id']}' LIMIT 1");
// RESET USER INFO
$user = new se_user(Array($user->user_info['user_id']));
// UPDATE COOKIES
$user->user_setcookies();
$result = 191;
}
В tpl дизайн вк такого как сейчас так что делаем сами под себя так как вам надо...
HTML:
<div id="settings_panel" class="clear_fix">
<div class="settings_section">
<h2>Дополнительные сервисы</h2>
Укажите ссылки, которые Вы хотели бы видеть в меню слева:
<form action='user_account.php' method='post' name='info'>
<div id="settings_services">
<div class="settings_service_row clear_fix">
<div class="settings_label fl_l ta_r" id="settings_label_friends">
<input type='checkbox' name='friends' id='friends' value='1' {if $user->user_info.friends == 1} checked='checked'{/if}></div>
<div>
<div></div>Мои Друзья
</div>
</div>
<div class="settings_service_row clear_fix">
<div class="settings_label fl_l ta_r" id="settings_label_photos">
<input type='checkbox' name='photos' id='photos' value='1' {if $user->user_info.photos == 1} checked='checked'{/if}></div>
<div>
<div></div>Мои Фотографии
</div>
</div>
<div class="settings_service_row clear_fix">
<div class="settings_label fl_l ta_r" id="settings_label_video">
<input type='checkbox' name='video' id='video' value='1' {if $user->user_info.video == 1} checked='checked'{/if}></div>
<div>
<div></div>Мои Видеозаписи
</div>
</div>
<div class="settings_service_row clear_fix">
<div class="settings_label fl_l ta_r" id="settings_label_audio">
<input type='checkbox' name='audio' id='audio' value='1' {if $user->user_info.audio == 1} checked='checked'{/if}></div>
<div>
<div></div>Мои Аудиозаписи
</div>
</div>
<div class="settings_service_row clear_fix">
<div class="settings_label fl_l ta_r" id="settings_label_mail">
<input type='checkbox' name='mail' id='mail' value='1' {if $user->user_info.mail == 1} checked='checked'{/if}></div>
<div>
<div></div>Мои Сообщения
</div>
</div>
<div class="settings_service_row clear_fix">
<div class="settings_label fl_l ta_r" id="settings_label_blog">
<input type='checkbox' name='blog' id='blog' value='1' {if $user->user_info.blog == 1} checked='checked'{/if}></div>
<div>
<div></div>Мои Заметки
</div>
</div>
<div class="settings_service_row clear_fix">
<div class="settings_label fl_l ta_r" id="settings_label_groups">
<input type='checkbox' name='groups' id='groups' value='1' {if $user->user_info.groups == 1} checked='checked'{/if}></div>
<div>
<div></div>Мои Группы
</div>
</div>
<div class="settings_service_row clear_fix">
<div class="settings_label fl_l ta_r" id="settings_label_news">
<input type='checkbox' name='news' id='news' value='1' {if $user->user_info.news == 1} checked='checked'{/if}></div>
<div>
<div></div>Мои Новости
</div>
</div>
<div class="settings_service_row clear_fix">
<div class="settings_label fl_l ta_r" id="settings_label_docs">
<input type='checkbox' name='opin' id='opin' value='1' {if $user->user_info.opin == 1} checked='checked'{/if}></div>
<div>
<div></div>Мнения
</div>
</div>
<br>
<input type='hidden' name='task' value='dosave1'><button>Сохранить изменения</button>
</form>
</div>
</div>
<br>
А вот и самое меню каторое будет скрываться
Code:
<ol>
<li id="myprofile" class="clear_fix">
<a href="/user_editprofile.php" onclick="return nav.go(this, event);" class="edit fl_r">ред.</a>
<a href="{$url->url_create("profile", $user->user_info.user_username)}" onclick="return nav.go(this, event, {literal}{noback: true}{/literal})" class="hasedit fl_l">Моя Страница</a>
</li>
{if $user->user_info.friends == "1"}
{if $total_friend_requests > 0}
<li id="l_fr">
<a href="/user_friends_requests.php" onclick="return nav.go(this, event, {literal}{noback: true, params: {_ref: 'left_nav'}}{/literal});" class="left_row">
<span class="left_label inl_bl">Мои Друзья</span>
<span class="left_count_wrap inl_bl">
<span class="inl_bl left_count" >{$total_friend_requests}</span></span></a></li>
{else}
<li id="l_fr">
<a href="/user_friends.php" onclick="return nav.go(this, event, {literal}{noback: true, params: {_ref: 'left_nav'}}{/literal});" class="left_row">
<span class="left_label inl_bl">Мои Друзья</span>
<span class="left_count_wrap inl_bl">
</span></a></li>
{/if}
{/if}
{if $user->user_info.photos == "1"}
<li id="l_ph">
<a href="/user_album.php" onclick="return nav.go(this, event, {literal}{noback: true, params: {_ref: 'left_nav'}}{/literal});" class="left_row">
<span class="left_label inl_bl">Мои Фотографии</span>
<span class="left_count_wrap inl_bl"></span></a></li>
{/if}
{if $user->user_info.video == "1"}
<li id="l_vid">
<a href="/user_video.php" onclick="return nav.go(this, event, {literal}{noback: true, params: {_ref: 'left_nav'}}{/literal});" class="left_row">
<span class="left_label inl_bl">Мои Видеозаписи</span>
<span class="left_count_wrap inl_bl"></span></a></li>
{/if}
{if $user->user_info.audio == "1"}
<li>
<a href="/user_music.php" onclick="return nav.go(this, event, {literal}{noback: true, params: {_ref: 'left_nav'}}{/literal});" class="left_row">
<span class="left_label inl_bl">Мои Аудиозаписи</span>
<span class="left_count_wrap inl_bl"></span></a></li>{/if}
{if $user->user_info.mail == "1"}
<li id="l_msg">
<a href="/user_messages.php" class="left_row">
<span class="left_label inl_bl">Мои Сообщения</span>
{if $user_unread_pms >0}<span class="left_count_wrap inl_bl">
<span class="inl_bl left_count" >{$user_unread_pms}</span></span>{/if}</a></li>{/if}
{if $user->user_info.blog == "1"}
<li id="l_nts">
<a href="/user_blog.php" class="left_row">
<span class="left_label inl_bl">Мои Заметки</span>
<span class="left_count_wrap inl_bl"></span></a></li>{/if}
{if $user->user_info.groups == "1"}
<li id="l_gr">
<a href="/user_groups.php" class="left_row">
<span class="left_label inl_bl">Мои Группы</span>
{if $total_invites > 0}<span class="left_count_wrap inl_bl">
<span class="inl_bl left_count" >{$total_invites}</span></span>{/if}</a></li>
{/if}
{if $user->user_info.news == "1"}
<li id="l_nws">
<a href="/user_home.php" class="left_row">
<span class="left_label inl_bl">Мои Новости</span>
<span class="left_count_wrap inl_bl"></span></a></li>{/if}
<li id="l_set">
<a href="/user_account.php" class="left_row">
<span class="left_label inl_bl">Мои Настройки</span>
<span class="left_count_wrap inl_bl"></span></a></li>
<div class="more_div"></div>
{if $user->user_info.opin == "1"}
<li id="l_ap">
<a href="/opinions.php" class="left_row">
<span class="left_label inl_bl">Мнения</span>
{if $total_my_checkbox != 0}<span class="left_count_wrap inl_bl">
<span class="inl_bl left_count" >{$total_my_checkbox}</span></span>{/if}</a></li>{/if}
</ol>
мод полностью рабочий!