Меню сайта
Users Hide (v2) - для DLE 10.4 - 14.0 и выше

Users Hide - небольшой хак который показывает содержимое, для определенных пользователей!
Ручная установка
1. Открыть: /engine/modules/functions.php найти
function dle_session( $sid = false ) {
Выше вставить
function users_hide($go, $stop){
global $member_id;
$go = explode(",", strtolower($go));
if ($member_id['user_id'] == 1 or in_array(strtolower($member_id['name']), $go))
return $stop;
else {
$user_ok = array();
foreach ($go as $users) {
$user_ok[] = "<b>" . $users . "</b>";
}
return "<div class=\"quote\">Ссылка доступна только для пользователей: " . implode(', ', $user_ok) . "</div>";
}
}
2. Открыть: /engine/modules/show.short.php найти
if( isset($view_template) AND $view_template == "rss" ) {
Выше вставить
$row['short_story'] = preg_replace("#\[users_hide=(.*?)\](.*?)\[/users_hide\]#ies", "users_hide('$1', '$2')", $row['short_story']);
3. Открыть: /engine/modules/show.full.php найти
$tpl->set( '{short-story}', $row['short_story'] );
Выше вставить
$row['short_story'] = preg_replace("#\[users_hide=(.*?)\](.*?)\[/users_hide\]#ies", "users_hide('$1', '$2')", $row['short_story']);
$row['full_story'] = preg_replace("#\[users_hide=(.*?)\](.*?)\[/users_hide\]#ies", "users_hide('$1', '$2')", $row['full_story']);
4. Открыть: /engine/modules/show.custom.php найти
$tpl->set( '{short-story}', $row['short_story'] );
Выше вставить
$row['short_story'] = preg_replace("#\[users_hide=(.*?)\](.*?)\[/users_hide\]#ies", "users_hide('$1', '$2')", $row['short_story']);
5. Открыть: /engine/classes/comments.class.php найти
$tpl->set( '{comment}', "<div id="'comm-id- . $row['id'] . ">" . stripslashes( $row['text'] ) . "</div>" );
Выше вставить
$row['text'] = preg_replace("#\[users_hide=(.*?)\](.*?)\[/users_hide\]#ies", "users_hide('$1', '$2')", $row['text']);
Готово!
Как все это использовать?
[users_hide=X,X,X] ссылка [/users_hide]
Данный хайд вы можете использовать в новостях и комментариях!
P.S На пользователя с ID==1 данный хайд не распространяется!
Автор: SX2
Проверенно на: DLE 10.4 - 14.0 и выше
Скачать Users Hide (v2)
Информация
Посетители, находящиеся в группе Гости, не могут оставлять комментарии к данной публикации.
Популярное за день
UniSite CMS (4.11) [Nulled]
Просмотров: (2 449 + 4)
Avone (5.5.0)
Просмотров: (511 + 4)
Bookory (2.2.5) [Nulled]
Просмотров: (43 + 3)
Zaira (1.0.0)
Просмотров: (25 + 3)
Slider Revolution (6.7.35) [Nulled]
Просмотров: (6 360 + 2)
WP Rocket (3.19.2.1 [Бесконечная лицензия]) [Nulled]
Просмотров: (3 818 + 2)
Ohio (3.5.6 + RUS) [Nulled]
Просмотров: (2 388 + 2)
ChatNet (1.11.0) [Nulled]
Просмотров: (2 137 + 2)
WP All Export Pro (1.9.10) [Nulled]
Просмотров: (2 015 + 2)
WP All Import Pro WooCommerce Addon (4.0.1 Beta 2.1) [Nulled]
Просмотров: (1 961 + 2)
Products Catalog (CSV, Excel, Xml) Export (4.1.1)
Просмотров: (995 + 2)
Bookworm (1.2.5)
Просмотров: (177 + 2)
Geekfolio (1.4)
Просмотров: (65 + 2)
Elementor PRO (3.30.1 Pro + RUS) [Nulled]
Просмотров: (14 451 + 1)
Journal (3.2.5) [Nulled]
Просмотров: (8 019 + 1)
Yoast SEO Premium (25.5.0 + Premium Extensions) [Nulled]
Просмотров: (7 089 + 1)
Academy LMS (6.14.0 + Addons) [Nulled]
Просмотров: (2 323 + 1)
EasyPlex (2.3.0) [Nulled]
Просмотров: (2 273 + 1)
Jannah News (7.5.1) [Nulled]
Просмотров: (2 165 + 1)
AffiliateWP (2.28.1 + Addons) [Nulled]
Просмотров: (1 837 + 1)
Meow Gallery Pro