Раздер Название темы Ответов Последний
Графика для сайта Shareman 3.70 RUS/2010 0 mandelsonsouggisse
Изготовление контента Нужен контент 10 ali7875
DataLife Engine Проблема регистрации. 1 JimaX
DataLife Engine Модальное окно в DataLife Engine 3 lionprizrak
DataLife Engine Настройка robots.txt 8 Prizrak_2012
Стол заказов на cmsko.ru Мини-чат. 2 JimaX
Общение пользователей Статьи 3 nastroenie
Хостинг TneHost - Хстинг провайдер 10 ali7875
DataLife Engine Установка банеров 9 JimaX
DataLife Engine Помогите с установой. dle95 2 nastroenie
Яндекс Apdate
Апдейты Яndex тИЦ
06.10.2015Последний |
13.08.2015
09.06.2015
Апдейты Яndex выдачи
09.10.2015Последний |
27.09.2015
23.09.2015
Апдейты ЯКаталога
07.10.2015Последний |
05.10.2015
01.10.2015

Информация
Главная страница » DLE » DLE Модули » Адрес новости + Соц закладки в модальном окне DLE
Адрес новости + Соц закладки в модальном окне DLE
» Просмотров: 2707 » Дата: 31-01-2011, 20:02 » Автор: NeoMurderer

Адрес новости + Соц закладки в модальном окне DLE
Хак добавляет кнопку "Поделиться", при нажатии на которую появляется окно с ссылками на новость и кнопками добавления в социальные сети и закладки.

Установка:
1. Скачать архив который в конце новости и скопируем папку "socimg" в templates/images/.

2. Открываем show.full.php:
Ищем:

$tpl->set( '{comments}', "<!--dlecomments-->" );



Выше ставим:

        $soc_set = "<center><div class="showLinki">
<div class="quote">
<input type="submit" class="fbutton" onclick="func_linki(); return false;"  value="Поделиться">
</div></div></center>
<div id="showLinki" title="<center>Пользуешься сервисами социальных закладок? Понравилась новость?
&#8595&#8595&#8595Тогда тебе сюда&#8595&#8595&#8595</center>" style="display:none;" >

<center><strong>HTML-cсылка:</strong>


        <input class="m_input" height:20px"; type="text" onclick="this.select();" onfocus="this.select();" readOnly value="<a href={$full_link}>{$metatags['title']}</a>">      


<strong>BB-cсылка:</strong>


        <input class="m_input" type="text" onclick="this.select();" onfocus="this.select();" readOnly value="[url=http://{$full_link}]{$metatags['title']}[/url]">


<strong>Прямая ссылка:</strong>


        <input class="m_input" type="text" onclick="this.select();" onfocus="this.select();" readOnly value="{$full_link}">
        <div class="clr ierrors"></div>
        <noindex>
        <div id="socializ">
                <a rel="nofollow" href="http://vkontakte.ru/" onclick="window.open('http://vkontakte.ru/share.php?url='+encodeURIComponent(location.href)+'&title='+encodeURIComponent(document.title)+'&desc='+encodeURIComponent(document.title)+'&tags={$metatags['keywords']}');return false;" title="Поделиться ВКонтакте">
                <img src="{THEME}/images/socimg/vkontakte.png" alt="Добавить закладку в ВКонтакте" border='0'></a>
                <a rel="nofollow" href="http://www.facebook.com/" onclick="window.open('http://www.facebook.com/sharer.php?u='+encodeURIComponent(location.href)+'&title='+encodeURIComponent(document.title)+'&desc='+encodeURIComponent(document.title)+'&tags={$metatags['keywords']}');return false;" title="Поделиться в Facebook">
                <img src="{THEME}/images/socimg/facebook.png" alt="Добавить закладку в Facebook" border='0'></a>
                <a rel="nofollow" href="http://twitter.com/" onclick="window.open('http://twitter.com/home?status=RT @ru_server '+encodeURIComponent(location.href)+'&title='+encodeURIComponent(document.title)+'&desc='+encodeURIComponent(document.title)+'&tags={$metatags['keywords']}');return false;" title="Добавить в Twitter">
                <img src="{THEME}/images/socimg/twitter.png" alt="Добавить закладку в Twitter" border='0'></a>
                <a rel="nofollow" href="http://www.google.com/" onclick="window.open('http://www.google.com/buzz/post?message='+encodeURIComponent(location.href)+'&title='+encodeURIComponent(document.title)+'&desc='+encodeURIComponent(document.title)+'&tags={$metatags['keywords']}');return false;" title="Добавить в Google Buzz">
                <img src="{THEME}/images/socimg/google-buzz.png" alt="Добавить закладку в Google Buzz" border='0'></a>
                <a rel="nofollow" href="http://bobrdobr.ru/" onclick="window.open('http://bobrdobr.ru/add.html?url='+encodeURIComponent(location.href)+'&title='+encodeURIComponent(document.title)+'&desc='+encodeURIComponent(document.title)+'&tags={$metatags['keywords']}');return false;" title="Забобрить">
                <img src="{THEME}/images/socimg/bobrdobr.png" alt="Добавить закладку в Бобрдобр" border='0'></a>
                <a rel="nofollow" href="http://memori.ru/" onclick="window.open('http://memori.ru/link/?sm=1&u_data[url]='+encodeURIComponent(location.href)+'&title='+encodeURIComponent(document.title)+'&desc='+encodeURIComponent(document.title)+'&tags={$metatags['keywords']}');return false;" title="Добавить в Memori.ru">
                <img src="{THEME}/images/socimg/memori.png" alt="Добавить закладку в Memori.ru" border='0'></a>
                </div></noindex>
        </center>
</div>

<script type="text/javascript">
function func_linki() {
$(function(){
    $('#showLinki').dialog({
        autoOpen: true,
        show: 'slide',
        hide: 'slide',
        width: 520,
        height: 300,
        buttons: {
            "Закрыть окно" : function() {
                $(this).dialog("close");
            },
        }

    });
});
}
</script>";
        
        $tpl->set( '{socseti}', $soc_set );

3.В fullstory.tpl в нужное место вставь

{socseti}

 

[attachment=154:socimg.rar]




Комментарии: 2
 (голосов: 1)
Amelion(Посетители) 9 февраля 2012 14:32
show.full.php
нашел в upload\engine\modules
но в этом файле нет строки
$tpl->set( '{comments}', "<!--dlecomments-->" );

куда вставлять?
JimaX(Гости) 9 февраля 2012 14:50
Amelion, данная строчка там есть, у вас какая версия движка ?
Уважаемый посетитель, Вы зашли к нам на сайт как незарегистрированный пользователь. Мы рекомендуем Вам бесплатно зарегистрироваться либо войти на сайт под своим именем.
Информация
Посетители, находящиеся в группе Гости, не могут оставлять комментарии к данной публикации.