Быстрый переход по страницам темы и форума (Alex_63)
В HTML низ:
Стиль:
Красным выделена ссылка на картинку стрелки.
Вариант картинки для форумов с темным фоном: http://test084tst.0pk.ru/files/0015/92/70/21719.png
Цитата
<!-- Быстрый переход по страницам темы и форума © Alex_63 -->
<script type="text/javascript">
var t_fID = $('html').find('link[rel="alternate"]').attr('href').split('id=')[1];if($('#pun-viewtopic').length){var UrlSpl='viewtopic'} if($('#pun-viewforum').length){var UrlSpl='viewforum'}if($('#pun-viewtopic, #pun-viewforum').length){$('div.pagelink:contains("»"), div.pagelink:contains("«")').each(function(){$('<form action="http://'+location.hostname+'/'+UrlSpl+'.php" method="get"><ul class="qJump-ul"><li class="quickJump"><label><input type="hidden" name="id" value="'+t_fID+'" />К странице: <input type="text" name="p" size="4" /></label> <input type="submit" class="button" value="Перейти" /></li></ul></form>').appendTo(this);$('<span class="openQJump"><img src="http://test084tst.0pk.ru/files/0015/92/70/93282.png" /></span>').prependTo(this);});$('.openQJump').click(function(){$(this).parent().find('.quickJump').fadeToggle(160);});}</script>
<script type="text/javascript">
var t_fID = $('html').find('link[rel="alternate"]').attr('href').split('id=')[1];if($('#pun-viewtopic').length){var UrlSpl='viewtopic'} if($('#pun-viewforum').length){var UrlSpl='viewforum'}if($('#pun-viewtopic, #pun-viewforum').length){$('div.pagelink:contains("»"), div.pagelink:contains("«")').each(function(){$('<form action="http://'+location.hostname+'/'+UrlSpl+'.php" method="get"><ul class="qJump-ul"><li class="quickJump"><label><input type="hidden" name="id" value="'+t_fID+'" />К странице: <input type="text" name="p" size="4" /></label> <input type="submit" class="button" value="Перейти" /></li></ul></form>').appendTo(this);$('<span class="openQJump"><img src="http://test084tst.0pk.ru/files/0015/92/70/93282.png" /></span>').prependTo(this);});$('.openQJump').click(function(){$(this).parent().find('.quickJump').fadeToggle(160);});}</script>
Стиль:
Код
<style>
.quickJump {
display: none;
position: absolute;
background: #f7f7f7;
color: #333;
font-size: 11px;
margin-top: 3px;
padding: 5px !important;
border: solid 1px #ccc;
border-radius: 5px;
}
.openQJump { cursor: pointer; margin-right: 1px; }
.openQJump > img { margin-bottom: -2px; margin-right: 2px; opacity: 1.0; }
.openQJump > img:hover { opacity: 0.8; }
</style>
.quickJump {
display: none;
position: absolute;
background: #f7f7f7;
color: #333;
font-size: 11px;
margin-top: 3px;
padding: 5px !important;
border: solid 1px #ccc;
border-radius: 5px;
}
.openQJump { cursor: pointer; margin-right: 1px; }
.openQJump > img { margin-bottom: -2px; margin-right: 2px; opacity: 1.0; }
.openQJump > img:hover { opacity: 0.8; }
</style>
Красным выделена ссылка на картинку стрелки.
Вариант картинки для форумов с темным фоном: http://test084tst.0pk.ru/files/0015/92/70/21719.png
Просмотров: 725, Загрузок: 0, Оценка: 5.0 (1)
Страницы: | |